Skip to content

Commit 99fcea0

Browse files
authored
Shorten the path of the "private" isolated-hoist-non-react-statics-do-not-use-this-in-your-code (#2551)
1 parent 9861a18 commit 99fcea0

File tree

7 files changed

+22
-17
lines changed

7 files changed

+22
-17
lines changed

.changeset/flat-schools-crash.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@emotion/react': patch
3+
---
4+
5+
Shorten the path of the "private" `isolated-hoist-non-react-statics-do-not-use-this-in-your-code` entrypoint to avoid exeeding path limitations on Windows.
+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{
2+
"main": "dist/emotion-react-_isolated-hnrs.cjs.js",
3+
"module": "dist/emotion-react-_isolated-hnrs.esm.js",
4+
"umd:main": "dist/emotion-react-_isolated-hnrs.umd.min.js",
5+
"browser": {
6+
"./dist/emotion-react-_isolated-hnrs.cjs.js": "./dist/emotion-react-_isolated-hnrs.browser.cjs.js",
7+
"./dist/emotion-react-_isolated-hnrs.esm.js": "./dist/emotion-react-_isolated-hnrs.browser.esm.js"
8+
},
9+
"sideEffects": false,
10+
"preconstruct": {
11+
"umdName": "emotionHoistNonReactStatics"
12+
}
13+
}

packages/react/isolated-hoist-non-react-statics-do-not-use-this-in-your-code/package.json

-13
This file was deleted.

packages/react/package.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
"dist",
1414
"jsx-runtime",
1515
"jsx-dev-runtime",
16-
"isolated-hoist-non-react-statics-do-not-use-this-in-your-code",
16+
"_isolated-hnrs",
1717
"types/*.d.ts",
1818
"macro.js",
1919
"macro.d.ts",
@@ -68,7 +68,7 @@
6868
"./index.js",
6969
"./jsx-runtime.js",
7070
"./jsx-dev-runtime.js",
71-
"./isolated-hoist-non-react-statics-do-not-use-this-in-your-code.js"
71+
"./_isolated-hnrs.js"
7272
],
7373
"umdName": "emotionReact"
7474
}

packages/react/src/theming.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
// @flow
22
import * as React from 'react'
33
import weakMemoize from '@emotion/weak-memoize'
4-
import hoistNonReactStatics from './isolated-hoist-non-react-statics-do-not-use-this-in-your-code'
4+
import hoistNonReactStatics from './_isolated-hnrs'
55

66
export const ThemeContext = /* #__PURE__ */ React.createContext<Object>({})
77
if (process.env.NODE_ENV !== 'production') {

packages/react/src/utils.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
// @flow
22
export let isBrowser = typeof document !== 'undefined'
33

4-
export const hasOwnProperty = Object.prototype.hasOwnProperty
4+
export const hasOwnProperty = {}.hasOwnProperty

0 commit comments

Comments
 (0)