Skip to content
This repository was archived by the owner on May 29, 2019. It is now read-only.

Commit 5d0c28f

Browse files
committed
fix: Distribute schema with package
1 parent 1730d46 commit 5d0c28f

File tree

4 files changed

+4
-3
lines changed

4 files changed

+4
-3
lines changed

package.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,8 @@
66
"license": "MIT",
77
"main": "dist/cjs.js",
88
"files": [
9-
"dist"
9+
"dist",
10+
"schema"
1011
],
1112
"scripts": {
1213
"start": "npm run build -- -w",
File renamed without changes.
File renamed without changes.

src/index.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ class ExtractTextPlugin {
2626
if (isString(options)) {
2727
options = { filename: options };
2828
} else {
29-
validateOptions(path.resolve(__dirname, './schema/plugin.json'), options, 'Extract Text Plugin');
29+
validateOptions(path.resolve(__dirname, '../schema/plugin.json'), options, 'Extract Text Plugin');
3030
}
3131
this.filename = options.filename;
3232
this.id = options.id != null ? options.id : ++nextId;
@@ -88,7 +88,7 @@ class ExtractTextPlugin {
8888
if (Array.isArray(options) || isString(options) || typeof options.options === 'object' || typeof options.query === 'object') {
8989
options = { use: options };
9090
} else {
91-
validateOptions(path.resolve(__dirname, './schema/loader.json'), options, 'Extract Text Plugin (Loader)');
91+
validateOptions(path.resolve(__dirname, '../schema/loader.json'), options, 'Extract Text Plugin (Loader)');
9292
}
9393
let loader = options.use;
9494
let before = options.fallback || [];

0 commit comments

Comments
 (0)