1
0
Fork 0

🚧 Updated dependencies, added Design

This commit is contained in:
Joost De Cock 2019-02-16 07:33:36 +01:00
parent fff45cb0a5
commit 814d8542b2
4 changed files with 907 additions and 3091 deletions

3942
package-lock.json generated

File diff suppressed because it is too large Load diff

View file

@ -57,7 +57,6 @@
},
"devDependencies": {
"@babel/core": "7.3.3",
"@babel/plugin-external-helpers": "7.2.0",
"@babel/preset-env": "7.3.1",
"babel-eslint": "^8.2.6",
"babel-plugin-istanbul": "4.1.6",
@ -92,19 +91,8 @@
],
"babel": {
"env": {
"develop": {
"plugins": [
"@babel/plugin-external-helpers"
]
},
"production": {
"plugins": [
"@babel/plugin-external-helpers"
]
},
"test": {
"plugins": [
"@babel/plugin-external-helpers",
"istanbul"
]
}

View file

@ -15,11 +15,11 @@ export default {
commonjs(),
babel({
exclude: "node_modules/**"
}),
terser({
output: {
preamble: `/**\n * ${name} | v${version}\n * ${description}\n * (c) ${new Date().getFullYear()} ${author}\n * @license ${license}\n */`
}
})
//terser({
// output: {
// preamble: `/**\n * ${name} | v${version}\n * ${description}\n * (c) ${new Date().getFullYear()} ${author}\n * @license ${license}\n */`
// }
//})
]
};

View file

@ -7,26 +7,26 @@ import * as utils from "./utils";
import { version } from "../package.json";
const create = function(config, plugins = false) {
const pattern = function(settings) {
Pattern.call(this, config);
if (Array.isArray(plugins)) for (let plugin of plugins) this.use(plugin);
if (plugins) this.use(plugins);
this.apply(settings);
return this;
};
// Set up inheritance
pattern.prototype = Object.create(Pattern.prototype);
pattern.prototype.constructor = pattern;
return pattern;
};
//const create = function(config, plugins = false) {
// const pattern = function(settings) {
// Pattern.call(this, config);
// if (Array.isArray(plugins)) for (let plugin of plugins) this.use(plugin);
// if (plugins) this.use(plugins);
// this.apply(settings);
//
// return this;
// };
//
// // Set up inheritance
// pattern.prototype = Object.create(Pattern.prototype);
// pattern.prototype.constructor = pattern;
//
// return pattern;
//};
export default {
version: version,
create,
// create,
Design,
Pattern,
Point,