Skip to content

Commit fe6c5da

Browse files
committed
chore: change build config
1 parent 9f36911 commit fe6c5da

File tree

6 files changed

+133
-658
lines changed

6 files changed

+133
-658
lines changed
File renamed without changes.

package.json

Lines changed: 22 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -2,39 +2,30 @@
22
"name": "@staffbase/plugins-client-sdk",
33
"version": "2.0.0",
44
"description": "Staffbase plugins client SDK for JavaScript",
5-
"main": "dist/plugins-client-sdk.js",
6-
"module": "dist/plugins-client-sdk.esm.js",
7-
"browser": "dist/plugins-client-sdk.umd.js",
5+
"main": "./dist/plugins-client-sdk.cjs.min.js",
6+
"module": "./dist/plugins-client-sdk.esm.min.js",
7+
"browser": "dist/plugins-client-sdk.umd.min.js",
88
"exports": {
9-
"require": "./dist/cjs/main.js",
10-
"import": "./dist/esm/main.js"
9+
"require": "./dist/plugins-client-sdk.cjs.min.js",
10+
"import": "./dist/plugins-client-sdk.esm.min.js"
1111
},
1212
"scripts": {
13-
"build:esm": "BABEL_ENV=esmUnbundled babel src --extensions '.js' --out-dir 'dist/esm' --source-maps",
14-
"build:cjs": "BABEL_ENV=cjs babel src --extensions '.js' --out-dir 'dist/cjs' --source-maps",
15-
"build:bundles": "BABEL_ENV=esmBundled rollup -c",
16-
"build": "yarn build:esm & yarn build:cjs & yarn build:bundles",
13+
"build": "yarn rollup -c",
1714
"prebuild": "yarn run lint",
15+
"postbuild": "yarn run size-limit",
1816
"prepare": "husky install",
1917
"dev": "rollup -c rollup.dev.mjs -w",
2018
"test-unit": "BABEL_ENV=test jest",
2119
"test-dev": "BABEL_ENV=test jest --watch",
22-
"lint": "yarn run lint-code && yarn run lint-size",
20+
"lint": "yarn run lint-code",
2321
"lint-code": "yarn eslint src test",
2422
"lint-size": "yarn size-limit",
2523
"fix": "eslint --fix 'src/**/*.js' 'test/**/*.js'",
2624
"doc": "mkdir -p doc && yarn --silent jsdoc2md src/main.js > doc/api.md",
2725
"release": "semantic-release"
2826
},
2927
"repository": "https://github.com/Staffbase/plugins-client-sdk.git",
30-
"keywords": [
31-
"staffbase",
32-
"client",
33-
"sdk",
34-
"javascript",
35-
"plugin",
36-
"api"
37-
],
28+
"keywords": ["staffbase", "client", "sdk", "javascript", "plugin", "api"],
3829
"author": "Staffbase GmbH (https://staffbase.com/)",
3930
"contributors": [
4031
"Stefan Staude <[email protected]>",
@@ -48,13 +39,21 @@
4839
"directories": {
4940
"test": "test"
5041
},
51-
"files": [
52-
"dist"
53-
],
42+
"files": ["dist"],
5443
"size-limit": [
5544
{
5645
"limit": "8 kB",
5746
"path": "src/main.js"
47+
},
48+
{
49+
"path": "dist/plugins-client-sdk.umd.min.js"
50+
},
51+
{
52+
"path": "dist/plugins-client-sdk.esm.min.js",
53+
"import": "{ openLinkExternal }"
54+
},
55+
{
56+
"path": "dist/plugins-client-sdk.esm.min.js"
5857
}
5958
],
6059
"dependencies": {
@@ -76,6 +75,7 @@
7675
"@rollup/plugin-commonjs": "24.0.1",
7776
"@rollup/plugin-node-resolve": "15.0.1",
7877
"@rollup/plugin-strip": "3.0.2",
78+
"@rollup/plugin-sucrase": "^5.0.1",
7979
"@rollup/plugin-terser": "^0.4.0",
8080
"@size-limit/preset-small-lib": "8.2.4",
8181
"@tmware/semantic-release-npm-github-publish": "^1.5.5",
@@ -93,11 +93,10 @@
9393
"jsdoc-to-markdown": "^8.0.0",
9494
"prettier": "^2.8.4",
9595
"regenerator-runtime": "0.13.11",
96-
"rollup": "^3.18.0",
96+
"rollup": "^3.19.1",
9797
"rollup-plugin-license": "3.0.1",
9898
"rollup-plugin-serve": "2.0.2",
9999
"rollup-plugin-strip-logger": "0.4.1",
100-
"rollup-plugin-template-html": "0.0.3",
101100
"size-limit": "^8.2.4"
102101
}
103102
}

0 commit comments

Comments
 (0)