Skip to content

Commit 005a1dd

Browse files
authored
Merge pull request #629 from thebuilder/beta
2 parents 4b1adce + 1f912ec commit 005a1dd

12 files changed

Lines changed: 3551 additions & 1988 deletions

File tree

.eslintignore

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
.idea
2+
node_modules
3+
4+
# production
5+
/build
6+
/dist
7+
/storybook/storybook-static

.github/workflows/release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313
- name: Install PNPM
1414
uses: pnpm/action-setup@v2
1515
with:
16-
version: 7
16+
version: 8
1717
- name: Setup Node.js
1818
uses: actions/setup-node@v3
1919
with:

.github/workflows/test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
- uses: actions/checkout@v3
1515
- uses: pnpm/action-setup@v2
1616
with:
17-
version: 7
17+
version: 8
1818
- name: Use Node.js ${{ matrix.node-version }}
1919
uses: actions/setup-node@v3
2020
with:

package.json

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,8 @@
33
"version": "8.26.1",
44
"description": "Monitor if a component is inside the viewport, using IntersectionObserver API",
55
"source": "./src/index.tsx",
6-
"main": "./dist/react-intersection-observer.js",
7-
"module": "./dist/react-intersection-observer.esm.js",
8-
"unpkg": "./dist/react-intersection-observer.umd.js",
6+
"main": "./dist/index.js",
7+
"module": "./dist/index.mjs",
98
"types": "./dist/index.d.ts",
109
"exports": {
1110
"./test-utils": {
@@ -14,8 +13,8 @@
1413
},
1514
".": {
1615
"types": "./dist/index.d.ts",
17-
"require": "./dist/react-intersection-observer.js",
18-
"default": "./dist/react-intersection-observer.modern.mjs"
16+
"require": "./dist/index.js",
17+
"default": "./dist/index.mjs"
1918
}
2019
},
2120
"author": "Daniel Schmidt",
@@ -28,12 +27,12 @@
2827
"scripts": {
2928
"prebuild": "rm -rf dist lib",
3029
"build": "run-s build:*",
31-
"build:bundle": "microbundle --name ReactIntersectionObserver --jsx React.createElement -f cjs,umd,es,modern --no-compress",
30+
"build:bundle": "tsup src/index.tsx",
3231
"build:utils": "tsc -p tsconfig.test.json",
3332
"build:copy": "node scripts/build-copy.js",
3433
"postbuild": "size-limit",
3534
"dev": "run-p dev:*",
36-
"dev:package": "microbundle --jsx React.createElement -f cjs,es,modern --no-compress --watch",
35+
"dev:package": "tsup src/index.tsx --watch",
3736
"dev:storybook": "pnpm --filter storybook dev",
3837
"lint": "eslint . --ext js,ts,tsx",
3938
"release": "np --contents dist",
@@ -100,19 +99,19 @@
10099
},
101100
"size-limit": [
102101
{
103-
"path": "dist/react-intersection-observer.esm.js",
102+
"path": "dist/index.mjs",
104103
"name": "InView",
105104
"import": "{ InView }",
106105
"limit": "1.8 kB"
107106
},
108107
{
109-
"path": "dist/react-intersection-observer.esm.js",
108+
"path": "dist/index.mjs",
110109
"name": "useInView",
111110
"import": "{ useInView }",
112111
"limit": "1.3 kB"
113112
},
114113
{
115-
"path": "dist/react-intersection-observer.esm.js",
114+
"path": "dist/index.mjs",
116115
"name": "observe",
117116
"import": "{ observe }",
118117
"limit": "1 kB"
@@ -126,11 +125,11 @@
126125
"@testing-library/jest-dom": "^5.16.5",
127126
"@testing-library/react": "^14.0.0",
128127
"@types/jest": "^29.5.2",
129-
"@types/react": "^18.2.7",
130-
"@types/react-dom": "^18.2.4",
131-
"@typescript-eslint/eslint-plugin": "^5.59.8",
132-
"@typescript-eslint/parser": "^5.59.8",
133-
"eslint": "^8.41.0",
128+
"@types/react": "^18.2.12",
129+
"@types/react-dom": "^18.2.5",
130+
"@typescript-eslint/eslint-plugin": "^5.59.11",
131+
"@typescript-eslint/parser": "^5.59.11",
132+
"eslint": "^8.43.0",
134133
"eslint-plugin-import": "^2.27.5",
135134
"eslint-plugin-jsx-a11y": "^6.7.1",
136135
"eslint-plugin-react": "^7.32.2",
@@ -144,8 +143,9 @@
144143
"react-dom": "^18.2.0",
145144
"simple-git-hooks": "^2.8.1",
146145
"size-limit": "^8.2.4",
147-
"typescript": "^4.9.5",
148-
"vitest": "^0.31.3"
146+
"tsup": "^7.0.0",
147+
"typescript": "^5.1.3",
148+
"vitest": "^0.32.2"
149149
},
150150
"pnpm": {
151151
"peerDependencyRules": {

0 commit comments

Comments
 (0)