Last change
on this file since bdd6491 was e29cc2e, checked in by Ema <ema_spirova@…>, 3 years ago |
primeNG components
|
-
Property mode
set to
100644
|
File size:
1.3 KB
|
Line | |
---|
1 | import resolve from '@rollup/plugin-node-resolve';
|
---|
2 | import commonjs from '@rollup/plugin-commonjs';
|
---|
3 | import sourceMaps from 'rollup-plugin-sourcemaps';
|
---|
4 | import typescript from '@rollup/plugin-typescript';
|
---|
5 | import json from 'rollup-plugin-json';
|
---|
6 |
|
---|
7 | const pkg = require('./package.json');
|
---|
8 |
|
---|
9 | const banner = `/*
|
---|
10 | * ${pkg.name} ${pkg.version} <${pkg.homepage}>
|
---|
11 | * Copyright (c) ${(new Date()).getFullYear()} ${pkg.author.name} <${pkg.author.url}>
|
---|
12 | * Released under ${pkg.license} License
|
---|
13 | */`;
|
---|
14 |
|
---|
15 | export default {
|
---|
16 | input: `src/index.ts`,
|
---|
17 | output: [
|
---|
18 | { file: pkg.main, name: pkg.name, format: 'umd', banner, sourcemap: true },
|
---|
19 | { file: pkg.module, format: 'esm', banner, sourcemap: true },
|
---|
20 | ],
|
---|
21 | external: [],
|
---|
22 | watch: {
|
---|
23 | include: 'src/**',
|
---|
24 | },
|
---|
25 | plugins: [
|
---|
26 | // Allow node_modules resolution, so you can use 'external' to control
|
---|
27 | // which external modules to include in the bundle
|
---|
28 | // https://github.com/rollup/rollup-plugin-node-resolve#usage
|
---|
29 | resolve(),
|
---|
30 | // Allow json resolution
|
---|
31 | json(),
|
---|
32 | // Compile TypeScript files
|
---|
33 | typescript(),
|
---|
34 | // Allow bundling cjs modules (unlike webpack, rollup doesn't understand cjs)
|
---|
35 | commonjs(),
|
---|
36 |
|
---|
37 | // Resolve source maps to the original source
|
---|
38 | sourceMaps(),
|
---|
39 | ],
|
---|
40 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.