Socket
Socket
Sign inDemoInstall

@shopify/react-html

Package Overview
Dependencies
Maintainers
13
Versions
191
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@shopify/react-html - npm Package Compare versions

Comparing version 9.1.0 to 9.2.0

4

CHANGELOG.md

@@ -11,2 +11,6 @@ # Changelog

## 9.2.0 - 2019-08-26
- New `useLocale` hook for setting the `lang` attribute on HTML
## 9.1.0 - 2019-08-26

@@ -13,0 +17,0 @@

@@ -10,2 +10,3 @@ /// <reference types="react" />

export declare function useFavicon(source: string): void;
export declare function useLocale(locale: string): void;
export declare function useHtmlAttributes(htmlAttributes: FirstArgument<HtmlManager['addHtmlAttributes']>): void;

@@ -12,0 +13,0 @@ export declare function useBodyAttributes(bodyAttributes: FirstArgument<HtmlManager['addBodyAttributes']>): void;

@@ -48,2 +48,6 @@ "use strict";

exports.useFavicon = useFavicon;
function useLocale(locale) {
useDomEffect(function (manager) { return manager.addHtmlAttributes({ lang: locale }); }, [locale]);
}
exports.useLocale = useLocale;
function useHtmlAttributes(htmlAttributes) {

@@ -50,0 +54,0 @@ useDomEffect(function (manager) { return manager.addHtmlAttributes(htmlAttributes); }, [

2

package.json
{
"name": "@shopify/react-html",
"version": "9.1.0",
"version": "9.2.0",
"license": "MIT",

@@ -5,0 +5,0 @@ "description": "A component to render your react app with no static HTML.",

@@ -56,2 +56,6 @@ import {useEffect, useContext} from 'react';

export function useLocale(locale: string) {
useDomEffect(manager => manager.addHtmlAttributes({lang: locale}), [locale]);
}
export function useHtmlAttributes(

@@ -58,0 +62,0 @@ htmlAttributes: FirstArgument<HtmlManager['addHtmlAttributes']>,

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc