Skip to content

Commit 0156de2

Browse files
committed
feat: to monorepo with bun
BREAKING CHANGE: new bundler might cause different behavior
1 parent 275078e commit 0156de2

35 files changed

+1202
-3799
lines changed

.babelrc

Lines changed: 0 additions & 4 deletions
This file was deleted.

.gitignore

Lines changed: 42 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,45 @@
1+
# Dependencies
2+
node_modules
3+
.pnp
4+
.pnp.js
5+
6+
# Testing
7+
coverage
8+
9+
# Production
10+
dist
11+
build
12+
packages/*/dist
13+
packages/*/build
14+
15+
# Misc
16+
.DS_Store
17+
.env.local
18+
.env.development.local
19+
.env.test.local
20+
.env.production.local
21+
.env
22+
23+
# Logs
24+
npm-debug.log*
25+
yarn-debug.log*
26+
yarn-error.log*
27+
bun-debug.log*
28+
bun-error.log*
29+
30+
# Editor directories and files
31+
.idea
32+
.vscode
33+
*.suo
34+
*.ntvs*
35+
*.njsproj
36+
*.sln
37+
*.sw?
38+
39+
# Astro
40+
packages/docs/.astro
41+
packages/docs/dist
42+
143
# Logs
244
logs
345
*.log
@@ -38,7 +80,6 @@ bower_components
3880
build/Release
3981

4082
# Dependency directories
41-
node_modules/
4283
jspm_packages/
4384

4485
# Snowpack dependency directory (https://snowpack.dev/)

bun.lock

Lines changed: 1047 additions & 2689 deletions
Large diffs are not rendered by default.

package.json

Lines changed: 12 additions & 60 deletions
Original file line numberDiff line numberDiff line change
@@ -1,57 +1,20 @@
11
{
2-
"name": "react-netlify-forms",
3-
"version": "1.3.5",
4-
"homepage": "https://pyrax.github.io/react-netlify-forms",
5-
"bugs": {
6-
"url": "https://github.com/pyrax/react-netlify-forms/issues"
7-
},
8-
"description": "React components and hooks giving you the power of Netlify Forms. Start building serverless forms on Netlify with React.",
9-
"keywords": [
10-
"react",
11-
"netlify",
12-
"forms",
13-
"netlify-forms",
14-
"react-netlify-form",
15-
"react-netlify-forms"
2+
"name": "react-netlify-forms-monorepo",
3+
"private": true,
4+
"workspaces": [
5+
"packages/*"
166
],
17-
"author": "Björn Clees <piranhadev@gmail.com> (https://github.com/pyrax/)",
18-
"license": "MIT",
19-
"repository": "Pyrax/react-netlify-forms",
20-
"main": "dist/index.js",
21-
"module": "dist/index.modern.js",
22-
"source": "src/index.js",
23-
"engines": {
24-
"node": ">=10"
25-
},
267
"scripts": {
27-
"build": "microbundle-crl --no-compress --format modern,cjs",
28-
"start": "microbundle-crl watch --no-compress --format modern,cjs",
29-
"prepare": "bun run build",
30-
"test": "bun run test:lint && bun run test:build",
31-
"test:build": "bun run build",
32-
"test:lint": "eslint .",
33-
"docs:dev": "cd www && bun run dev",
34-
"docs:build": "cd www && bun run build",
35-
"docs:preview": "cd www && bun run preview",
36-
"prepare-deploy": "cd www && bun install && bun run clean && cp ../README.md README.md && cp ../LICENSE.md LICENSE.md",
37-
"predeploy:default": "bun run prepare-deploy && cd www && bun run build",
38-
"predeploy:prefix": "bun run prepare-deploy && cd www && bun run build:prefix",
39-
"deploy": "bun run build && bun run deploy:gh",
40-
"deploy:gh": "bun run build && bun run predeploy:prefix && gh-pages -d www/dist",
41-
"deploy:netlify": "bun run build && bun run predeploy:default && netlify deploy --prod --dir=www/dist"
42-
},
43-
"peerDependencies": {
44-
"react": "^16.8.0 || ^17.0.2 || ^18.0.0 || ^19.0.0"
8+
"build": "bun run --cwd packages/react-netlify-forms build",
9+
"dev": "bun run --cwd packages/docs dev",
10+
"test": "bun run --cwd packages/react-netlify-forms test",
11+
"lint": "bun run --cwd packages/react-netlify-forms test:lint",
12+
"docs:dev": "bun run --cwd packages/docs dev",
13+
"docs:build": "bun run --cwd packages/docs build",
14+
"docs:preview": "bun run --cwd packages/docs preview"
4515
},
4616
"devDependencies": {
47-
"@babel/core": "^7.21.8",
48-
"@babel/eslint-parser": "^7.21.8",
49-
"@babel/plugin-transform-regenerator": "^7.21.5",
50-
"@babel/preset-modules": "^0.1.5",
51-
"@babel/preset-react": "^7.18.6",
52-
"cross-env": "^7.0.2",
5317
"cz-conventional-changelog": "3.2.0",
54-
"esbuild": "^0.17.18",
5518
"eslint": "^8.40.0",
5619
"eslint-config-prettier": "^6.7.0",
5720
"eslint-config-react-app": "^7.0.1",
@@ -64,19 +27,8 @@
6427
"eslint-plugin-react": "^7.17.0",
6528
"eslint-plugin-standard": "^4.0.1",
6629
"gh-pages": "^2.2.0",
67-
"microbundle-crl": "^0.13.10",
6830
"netlify-cli": "^2.52.0",
69-
"npm-run-all": "^4.1.5",
70-
"prettier": "^2.0.4",
71-
"react": "^18.2.0",
72-
"react-dom": "^18.2.0",
73-
"react-scripts": "^5.0.1"
74-
},
75-
"files": [
76-
"dist"
77-
],
78-
"dependencies": {
79-
"react-google-recaptcha": "^2.1.0"
31+
"prettier": "^2.0.4"
8032
},
8133
"config": {
8234
"commitizen": {
File renamed without changes.

www/package.json renamed to packages/docs/package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"name": "www",
2+
"name": "@react-netlify-forms/docs",
33
"type": "module",
44
"version": "0.0.1",
55
"private": true,
@@ -18,8 +18,8 @@
1818
"astro": "^5.6.1",
1919
"react": "^19.1.0",
2020
"react-dom": "^19.1.0",
21-
"react-netlify-forms": "link:react-netlify-forms",
21+
"react-netlify-forms": "workspace:*",
2222
"sharp": "^0.32.5",
2323
"starlight-theme-rapide": "^0.5.1"
2424
}
25-
}
25+
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)