Skip to content

Commit

Permalink
refactor: remove useless namedExports option
Browse files Browse the repository at this point in the history
  • Loading branch information
PeachScript committed Nov 3, 2020
1 parent 3e41fa3 commit 797c9ba
Show file tree
Hide file tree
Showing 12 changed files with 7 additions and 27 deletions.
4 changes: 0 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -400,10 +400,6 @@ export default {

配置 rollup-plugin-commonjs 的 [include][https://github.com/rollup/rollup-plugin-commonjs#usage]

#### namedExports

配置 rollup-plugin-commonjs 的 [namedExports](https://github.com/rollup/rollup-plugin-commonjs#usage)

#### nodeResolveOpts

配置 [rollup-plugin-node-resolve](https://github.com/rollup/rollup-plugin-node-resolve) 参数。
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@

export default {
umd: {
minFile: false,
},
};

This file was deleted.

3 changes: 1 addition & 2 deletions packages/father-build/src/getRollupConfig.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ export default function(opts: IGetRollupConfigOpts): RollupOptions[] {
extraRollupPlugins = [],
autoprefixer: autoprefixerOpts,
include = /node_modules/,
namedExports,
runtimeHelpers: runtimeHelpersOpts,
replace: replaceOpts,
inject: injectOpts,
Expand Down Expand Up @@ -257,7 +256,7 @@ export default function(opts: IGetRollupConfigOpts): RollupOptions[] {
const extraUmdPlugins = [
commonjs({
include,
namedExports,
// namedExports options has been remove from https://github.com/rollup/plugins/pull/149
}),
];

Expand Down
1 change: 0 additions & 1 deletion packages/father-build/src/schema.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ const successValidates = {
cssModules: [true, false, {}],
autoprefixer: [{}],
include: ['node_modules', /node_modules/],
namedExports: [{}],
nodeResolveOpts: [{}],
runtimeHelpers: [true, false],
target: ['node', 'browser'],
Expand Down
3 changes: 0 additions & 3 deletions packages/father-build/src/schema.ts
Original file line number Diff line number Diff line change
Expand Up @@ -106,9 +106,6 @@ export default {
{ type: 'object' }
]
},
namedExports: {
type: 'object',
},
runtimeHelpers: {
type: 'boolean',
},
Expand Down
5 changes: 0 additions & 5 deletions packages/father-build/src/types.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,6 @@ interface IStringObject {
[prop: string]: string;
}

interface IStringArrayObject {
[prop: string]: string[];
}

interface IUmd {
globals?: IStringObject;
name?: string;
Expand All @@ -50,7 +46,6 @@ export interface IBundleOptions {
inject?: Object,
autoprefixer?: Object;
include?: string | RegExp;
namedExports?: IStringArrayObject;
runtimeHelpers?: boolean;
target?: 'node' | 'browser';
overridesByEntry?: {
Expand Down

0 comments on commit 797c9ba

Please sign in to comment.