Skip to content

Commit

Permalink
Merge pull request #329 from kamiazya/fix-to-rollup-build
Browse files Browse the repository at this point in the history
chaos: build with rollup
  • Loading branch information
kamiazya authored Jul 28, 2021
2 parents f04eb97 + 95aaf53 commit 641f8d3
Show file tree
Hide file tree
Showing 22 changed files with 350 additions and 297 deletions.
12 changes: 5 additions & 7 deletions component-libraries/aws/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
},
"scripts": {
"clean": "rimraf lib",
"build": "ts-node scripts/build",
"build": "rollup -c && prettier --write './lib/*'",
"watch": "tsc --watch"
},
"dependencies": {
Expand All @@ -43,13 +43,11 @@
"@types/prop-types": "^15.7.3",
"@types/react": "^16.9.35",
"@types/react-dom": "^16.9.8",
"@types/rimraf": "^3.0.0",
"rediagram": "^0.2.4",
"rimraf": "^3.0.2",
"rollup": "^2.32.0",
"rollup-plugin-dts": "^1.4.13",
"rollup-plugin-typescript2": "^0.28.0",
"ts-node": "^9.0.0",
"rollup": "^2.55.0",
"rollup-plugin-delete": "^2.0.0",
"rollup-plugin-dts": "^3.0.2",
"rollup-plugin-typescript2": "^0.30.0",
"typescript": "^4.0.2"
}
}
36 changes: 36 additions & 0 deletions component-libraries/aws/rollup.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
import typescript from 'rollup-plugin-typescript2';
import del from 'rollup-plugin-delete';
import dts from 'rollup-plugin-dts';

/** @type {import('rollup').RollupOptions[]} */
const options = [
{
input: './src/index.ts',
output: [
{
format: 'cjs',
file: './lib/index.js',
},
],
external: ['@rediagram/cdk', 'react', '@ts-graphviz/react', 'prop-types', 'path'],
plugins: [typescript()],
},
{
input: './lib/index.d.ts',
plugins: [
del({
targets: ['lib/**/*.d.ts', '!lib/index.d.ts'],
hook: 'buildEnd',
}),
dts(),
],
output: [
{
format: 'esm',
file: './lib/index.d.ts',
},
],
},
];

export default options;
31 changes: 0 additions & 31 deletions component-libraries/aws/scripts/build.ts

This file was deleted.

12 changes: 5 additions & 7 deletions component-libraries/firebase/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
},
"scripts": {
"clean": "rimraf lib",
"build": "ts-node scripts/build",
"build": "rollup -c && prettier --write './lib/*'",
"watch": "tsc --watch"
},
"dependencies": {
Expand All @@ -43,13 +43,11 @@
"@types/prop-types": "^15.7.3",
"@types/react": "^16.9.35",
"@types/react-dom": "^16.9.8",
"@types/rimraf": "^3.0.0",
"rediagram": "^0.2.4",
"rimraf": "^3.0.2",
"rollup": "^2.32.0",
"rollup-plugin-dts": "^1.4.13",
"rollup-plugin-typescript2": "^0.28.0",
"ts-node": "^9.0.0",
"rollup": "^2.55.0",
"rollup-plugin-delete": "^2.0.0",
"rollup-plugin-dts": "^3.0.2",
"rollup-plugin-typescript2": "^0.30.0",
"typescript": "^4.0.2"
}
}
36 changes: 36 additions & 0 deletions component-libraries/firebase/rollup.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
import typescript from 'rollup-plugin-typescript2';
import del from 'rollup-plugin-delete';
import dts from 'rollup-plugin-dts';

/** @type {import('rollup').RollupOptions[]} */
const options = [
{
input: './src/index.ts',
output: [
{
format: 'cjs',
file: './lib/index.js',
},
],
external: ['@rediagram/cdk', 'react', '@ts-graphviz/react', 'prop-types', 'path'],
plugins: [typescript()],
},
{
input: './lib/index.d.ts',
plugins: [
del({
targets: ['lib/**/*.d.ts', '!lib/index.d.ts'],
hook: 'buildEnd',
}),
dts(),
],
output: [
{
format: 'esm',
file: './lib/index.d.ts',
},
],
},
];

export default options;
31 changes: 0 additions & 31 deletions component-libraries/firebase/scripts/build.ts

This file was deleted.

12 changes: 5 additions & 7 deletions component-libraries/gcp/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
},
"scripts": {
"clean": "rimraf lib",
"build": "ts-node scripts/build",
"build": "rollup -c && prettier --write './lib/*'",
"watch": "tsc --watch"
},
"dependencies": {
Expand All @@ -43,13 +43,11 @@
"@types/prop-types": "^15.7.3",
"@types/react": "^16.9.35",
"@types/react-dom": "^16.9.8",
"@types/rimraf": "^3.0.0",
"rediagram": "^0.2.4",
"rimraf": "^3.0.2",
"rollup": "^2.32.0",
"rollup-plugin-dts": "^1.4.13",
"rollup-plugin-typescript2": "^0.28.0",
"ts-node": "^9.0.0",
"rollup": "^2.55.0",
"rollup-plugin-delete": "^2.0.0",
"rollup-plugin-dts": "^3.0.2",
"rollup-plugin-typescript2": "^0.30.0",
"typescript": "^4.0.2"
}
}
36 changes: 36 additions & 0 deletions component-libraries/gcp/rollup.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
import typescript from 'rollup-plugin-typescript2';
import del from 'rollup-plugin-delete';
import dts from 'rollup-plugin-dts';

/** @type {import('rollup').RollupOptions[]} */
const options = [
{
input: './src/index.ts',
output: [
{
format: 'cjs',
file: './lib/index.js',
},
],
external: ['@rediagram/cdk', 'react', '@ts-graphviz/react', 'prop-types', 'path'],
plugins: [typescript()],
},
{
input: './lib/index.d.ts',
plugins: [
del({
targets: ['lib/**/*.d.ts', '!lib/index.d.ts'],
hook: 'buildEnd',
}),
dts(),
],
output: [
{
format: 'esm',
file: './lib/index.d.ts',
},
],
},
];

export default options;
31 changes: 0 additions & 31 deletions component-libraries/gcp/scripts/build.ts

This file was deleted.

12 changes: 5 additions & 7 deletions packages/cdk/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
"license": "MIT",
"scripts": {
"clean": "rimraf lib",
"build": "ts-node scripts/build",
"build": "rollup -c && prettier --write './lib/*'",
"watch": "tsc --watch"
},
"peerDependencies": {
Expand All @@ -37,12 +37,10 @@
"@types/prop-types": "^15.7.3",
"@types/react": "^16.9.35",
"@types/react-dom": "^16.9.8",
"@types/rimraf": "^3.0.0",
"rimraf": "^3.0.2",
"rollup": "^2.32.0",
"rollup-plugin-dts": "^1.4.13",
"rollup-plugin-typescript2": "^0.28.0",
"ts-node": "^9.0.0",
"rollup": "^2.55.0",
"rollup-plugin-delete": "^2.0.0",
"rollup-plugin-dts": "^3.0.2",
"rollup-plugin-typescript2": "^0.30.0",
"typescript": "^4.0.2"
},
"dependencies": {
Expand Down
36 changes: 36 additions & 0 deletions packages/cdk/rollup.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
import typescript from 'rollup-plugin-typescript2';
import del from 'rollup-plugin-delete';
import dts from 'rollup-plugin-dts';

/** @type {import('rollup').RollupOptions[]} */
const options = [
{
input: './src/index.ts',
output: [
{
format: 'cjs',
file: './lib/index.js',
},
],
external: ['@ts-graphviz/react', 'react', 'prop-types'],
plugins: [typescript()],
},
{
input: './lib/index.d.ts',
plugins: [
del({
targets: ['lib/**/*.d.ts', '!lib/index.d.ts'],
hook: 'buildEnd',
}),
dts(),
],
output: [
{
format: 'esm',
file: './lib/index.d.ts',
},
],
},
];

export default options;
31 changes: 0 additions & 31 deletions packages/cdk/scripts/build.ts

This file was deleted.

4 changes: 2 additions & 2 deletions packages/cli/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,8 @@
},
"devDependencies": {
"rimraf": "^3.0.2",
"rollup": "^2.32.0",
"rollup-plugin-typescript2": "^0.28.0",
"rollup": "^2.55.0",
"rollup-plugin-typescript2": "^0.30.0",
"ts-node": "^9.0.0"
}
}
Loading

0 comments on commit 641f8d3

Please sign in to comment.