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 8.0.8 to 8.0.9

6

CHANGELOG.md

@@ -13,2 +13,8 @@ # Changelog

## 8.0.9 - 2019-05-02
### Changed
- Removed the `isServer` option from the constructor for `HtmlManager` [#682](https://github.com/Shopify/quilt/pull/682)
## 8.0.6 - 2019-04-15

@@ -15,0 +21,0 @@

4

dist/manager.d.ts

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

effect: EffectKind;
private isServer;
private serializations;

@@ -22,5 +21,2 @@ private titles;

readonly state: State;
constructor({ isServer }?: {
isServer?: boolean | undefined;
});
reset({ includeSerializations }?: {

@@ -27,0 +23,0 @@ includeSerializations?: boolean | undefined;

@@ -7,4 +7,3 @@ "use strict";

var HtmlManager = /** @class */ (function () {
function HtmlManager(_a) {
var _b = (_a === void 0 ? {} : _a).isServer, isServer = _b === void 0 ? typeof document === 'undefined' : _b;
function HtmlManager() {
var _this = this;

@@ -20,3 +19,2 @@ this.effect = {

this.subscriptions = new Set();
this.isServer = isServer;
}

@@ -47,5 +45,2 @@ Object.defineProperty(HtmlManager.prototype, "state", {

var _this = this;
if (this.isServer) {
return function () { };
}
this.subscriptions.add(subscription);

@@ -73,5 +68,3 @@ return function () {

HtmlManager.prototype.setSerialization = function (id, data) {
if (this.isServer) {
this.serializations.set(id, data);
}
this.serializations.set(id, data);
};

@@ -78,0 +71,0 @@ HtmlManager.prototype.getSerialization = function (id) {

{
"name": "@shopify/react-html",
"version": "8.0.8",
"version": "8.0.9",
"license": "MIT",

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

@@ -26,3 +26,2 @@ import {EffectKind} from '@shopify/react-effect';

private isServer: boolean;
private serializations = getSerializationsFromDocument();

@@ -44,6 +43,2 @@ private titles: Title[] = [];

constructor({isServer = typeof document === 'undefined'} = {}) {
this.isServer = isServer;
}
reset({includeSerializations = false} = {}) {

@@ -61,6 +56,2 @@ this.titles = [];

subscribe(subscription: Subscription) {
if (this.isServer) {
return () => {};
}
this.subscriptions.add(subscription);

@@ -92,5 +83,3 @@ return () => {

setSerialization(id: string, data: unknown) {
if (this.isServer) {
this.serializations.set(id, data);
}
this.serializations.set(id, data);
}

@@ -97,0 +86,0 @@

Sorry, the diff of this file is not supported yet

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