Skip to content
This repository has been archived by the owner on Feb 15, 2022. It is now read-only.

Commit

Permalink
Cleaned up build
Browse files Browse the repository at this point in the history
  • Loading branch information
stephenwf committed May 7, 2021
1 parent d1b2438 commit 18edfce
Show file tree
Hide file tree
Showing 101 changed files with 2,676 additions and 25,857 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,4 @@ packages/*/umd
examples/*/lib
examples/*/umd
*.tsbuildinfo
stats.html
29 changes: 0 additions & 29 deletions azure-pipelines.yml

This file was deleted.

59 changes: 59 additions & 0 deletions create-rollup-config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
import typescript from '@rollup/plugin-typescript';
import resolve from '@rollup/plugin-node-resolve';
import commonjs from '@rollup/plugin-commonjs';
import { terser } from 'rollup-plugin-terser';
import visualizer from 'rollup-plugin-visualizer';
import replace from 'rollup-plugin-replace';
import compiler from '@ampproject/rollup-plugin-closure-compiler';

export function createRollupConfig(globalName, pkg, external = []) {
return [
{
input: 'src/index.ts',
output: [
{
file: pkg.web,
name: globalName,
format: 'umd',
sourcemap: true,
},
],
plugins: [
typescript({ target: 'es5' }),
replace({
'process.env.NODE_ENV': JSON.stringify('production'),
}),
resolve({ browser: true }), // so Rollup can find `ms`
commonjs({ extensions: ['.js', '.ts'] }), // the ".ts" extension is required
terser(),
compiler(),
],
external,
},
{
input: 'src/index.ts',
output: [
{
file: pkg.main,
format: 'cjs',
sourcemap: true,
},
{
file: pkg.module,
format: 'es',
sourcemap: true,
},
],
external: ['crypto', ...external, ...Object.keys(pkg.dependencies)],
plugins: [
typescript(),
replace({
'process.env.NODE_ENV': JSON.stringify('production'),
}),
resolve(), // so Rollup can find `ms`
commonjs({ extensions: ['.js', '.ts'] }), // the ".ts" extension is required
visualizer(),
],
},
];
}
2 changes: 0 additions & 2 deletions documentation/.gitignore

This file was deleted.

27 changes: 0 additions & 27 deletions documentation/package.json

This file was deleted.

Binary file removed documentation/public/images/contexts.png
Binary file not shown.
Binary file removed documentation/public/images/selector.png
Binary file not shown.
Binary file removed documentation/public/images/typescript-01.png
Binary file not shown.
56 changes: 0 additions & 56 deletions documentation/src/docs/00-introduction/01-background.md

This file was deleted.

160 changes: 0 additions & 160 deletions documentation/src/docs/00-introduction/02-iiif.md

This file was deleted.

Loading

0 comments on commit 18edfce

Please sign in to comment.