Skip to content

Commit

Permalink
build(parcel): replace rollup with parcel 2
Browse files Browse the repository at this point in the history
Building with rollup was tedious and we were unsure if we were targetting all platforms and bundles.
Now we know becuase it does it all!

BREAKING CHANGE: packagejson#module was removed because the file is no longer being generated.
  • Loading branch information
waynevanson committed Sep 27, 2020
1 parent f34c861 commit 3876be2
Show file tree
Hide file tree
Showing 9 changed files with 1,544 additions and 823 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@ temp
dist
# todo - get story book only when releasing.
storybook-static
.parcel-cache
11 changes: 0 additions & 11 deletions config/move-files.ts

This file was deleted.

29 changes: 0 additions & 29 deletions config/rollup.config.js

This file was deleted.

24 changes: 0 additions & 24 deletions config/tsconfig.rollup.json

This file was deleted.

30 changes: 13 additions & 17 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,20 +8,19 @@
"version": "5.0.5",
"private": false,
"main": "dist/index.js",
"module": "dist/index.es.js",
"types": "dist/index.d.ts",
"files": [
"dist"
],
"scripts": {
"commit": "cz",
"prepublishOnly": "yarn build",
"start": "parcel examples/index.html --out-dir temp/server --cache-dir temp/cache ",
"build": "yarn build:rollup && yarn build:tsc",
"build:rollup": " rollup --config config/rollup.config.js",
"build:tsc": "ts-node config/move-files.ts",
"build": "yarn build:parcel",
"build:storybook": "build-storybook",
"storybook": "start-storybook -p 6006",
"build:parcel": "parcel build ./src/index.ts",
"serve": "npm-run-all --parallel serve:*",
"serve:parcel": "parcel watch ./src/index.ts",
"serve:storybook": "start-storybook -p 6006",
"style": "yarn style:format && yarn style:lint",
"style:format": "prettier -w src",
"style:lint": "eslint src/**"
Expand Down Expand Up @@ -85,10 +84,10 @@
"@commitlint/config-conventional": "^11.0.0",
"@semantic-release/changelog": "^5.0.1",
"@semantic-release/git": "^9.0.0",
"@storybook/addon-actions": "^6.0.21",
"@storybook/addon-essentials": "^6.0.21",
"@storybook/addon-links": "^6.0.21",
"@storybook/react": "^6.0.21",
"@storybook/addon-actions": "^6.0.22",
"@storybook/addon-essentials": "^6.0.22",
"@storybook/addon-links": "^6.0.22",
"@storybook/react": "^6.0.22",
"@types/classnames": "^2.2.10",
"@types/jest": "^26.0.14",
"@types/node": "14.11.2",
Expand All @@ -97,25 +96,22 @@
"@types/sortablejs": "^1.10.0",
"@typescript-eslint/eslint-plugin": "^4.2.0",
"@typescript-eslint/parser": "^4.2.0",
"babel-loader": "^8.1.0",
"commitizen": "^4.2.1",
"copy-dir": "^1.3.0",
"cz-conventional-changelog": "^3.3.0",
"eslint": "^7.9.0",
"eslint": "^7.10.0",
"eslint-plugin-react": "^7.21.2",
"husky": "^4.3.0",
"jest": "^26.4.2",
"parcel-bundler": "^1.12.4",
"npm-run-all": "^4.1.5",
"parcel": "^2.0.0-beta.1",
"prettier": "^2.1.2",
"react": "^16.13.1",
"react-dom": "^16.13.1",
"react-is": "^16.13.1",
"rollup": "^2.28.2",
"rollup-plugin-commonjs": "^10.1.0",
"rollup-plugin-typescript2": "^0.27.2",
"semantic-release": "^17.1.2",
"sortablejs": "^1.10.0",
"storybook": "^6.0.21",
"storybook": "^6.0.22",
"ts-jest": "^26.4.0",
"ts-node": "^9.0.0",
"typescript": "^4.0.3"
Expand Down
3 changes: 2 additions & 1 deletion stories/multi-drag/multi-drag.stories.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
// also exported from '@storybook/react' if you can deal with breaking changes in 6.1
import { Meta } from "@storybook/react";
import { ReactSortable, ReactSortableProps } from "../../src";
import { ReactSortable } from "../../dist";
import { ReactSortableProps } from "../../src";
import { ULLITemplate, ULLITemplateProps } from "../templates/ul-li";

export default {
Expand Down
3 changes: 2 additions & 1 deletion stories/unary-lists/simple-list.stories.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
// also exported from '@storybook/react' if you can deal with breaking changes in 6.1
import { Meta } from "@storybook/react";
import { ReactSortableProps, ReactSortable } from "../../src";
import { ReactSortable } from "../../dist";
import { ReactSortableProps } from "../../src";
import { ULLITemplate, ULLITemplateProps } from "../templates/ul-li";

export default {
Expand Down
18 changes: 9 additions & 9 deletions tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
{
"compilerOptions": {
"incremental": true, /* Enable incremental compilation */
"strict": true, /* Enable all strict type-checking options. */
"target": "es5", /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', 'ES2018', 'ES2019' or 'ESNEXT'. */
"module": "commonjs", /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', or 'ESNext'. */
"jsx": "react", /* Specify JSX code generation: 'preserve', 'react-native', or 'react'. */
"allowSyntheticDefaultImports": true,
"esModuleInterop": true, /* Enables emit interoperability between CommonJS and ES Modules via creation of namespace objects for all imports. Implies 'allowSyntheticDefaultImports'. */
"strictNullChecks": true
"strict": true,
"target": "es5",
"esModuleInterop": true,
"jsx": "react",
"resolveJsonModule": true,
"sourceMap": true,
"lib": ["es2015", "DOM"]
},
}
"include": ["src"]
}
Loading

0 comments on commit 3876be2

Please sign in to comment.