flarum-webpack-config
Advanced tools
Comparing version 2.0.2 to 3.0.0
{ | ||
"name": "flarum-webpack-config", | ||
"version": "2.0.2", | ||
"type": "module", | ||
"version": "3.0.0", | ||
"description": "Webpack config for Flarum JS and TS transpilation.", | ||
"main": "index.js", | ||
"main": "src/index.cjs", | ||
"author": "Flarum Team", | ||
"license": "MIT", | ||
"prettier": "@flarum/prettier-config", | ||
"peerDependencies": { | ||
@@ -12,21 +14,42 @@ "webpack": "^5.76.0" | ||
"dependencies": { | ||
"@babel/core": "^7.16.0", | ||
"@babel/plugin-proposal-class-properties": "^7.16.0", | ||
"@babel/plugin-proposal-private-methods": "^7.16.0", | ||
"@babel/plugin-transform-object-assign": "^7.16.0", | ||
"@babel/plugin-transform-react-jsx": "^7.16.0", | ||
"@babel/plugin-transform-runtime": "^7.16.0", | ||
"@babel/preset-env": "^7.16.0", | ||
"@babel/preset-react": "^7.16.0", | ||
"@babel/preset-typescript": "^7.16.0", | ||
"@babel/runtime": "^7.16.0", | ||
"babel-loader": "^8.2.3", | ||
"typescript": "^4.4.4", | ||
"@babel/core": "^7.20.2", | ||
"@babel/plugin-proposal-class-properties": "^7.18.6", | ||
"@babel/plugin-proposal-private-methods": "^7.18.6", | ||
"@babel/plugin-transform-object-assign": "^7.18.6", | ||
"@babel/plugin-transform-react-jsx": "^7.19.0", | ||
"@babel/plugin-transform-runtime": "^7.19.6", | ||
"@babel/preset-env": "^7.20.2", | ||
"@babel/preset-react": "^7.18.6", | ||
"@babel/preset-typescript": "^7.18.6", | ||
"@babel/runtime": "^7.20.1", | ||
"babel-loader": "^9.1.0", | ||
"loader-utils": "^1.4.0", | ||
"schema-utils": "^3.0.0", | ||
"typescript": "^4.9.3", | ||
"webpack": "^5.76.0", | ||
"webpack-bundle-analyzer": "^4.5.0" | ||
"webpack-bundle-analyzer": "^4.7.0" | ||
}, | ||
"devDependencies": { | ||
"prettier": "^2.4.1" | ||
"@flarum/prettier-config": "^1.0.0", | ||
"babel-jest": "^29.5.0", | ||
"jest": "^29.5.0", | ||
"memfs": "^3.5.3", | ||
"prettier": "^2.8.0" | ||
}, | ||
"packageManager": "yarn@3.1.0" | ||
"scripts": { | ||
"dev": "echo 'skipping..'", | ||
"build": "echo 'skipping..'", | ||
"analyze": "echo 'skipping..'", | ||
"format": "prettier --write .", | ||
"format-check": "prettier --check .", | ||
"clean-typings": "echo 'skipping..'", | ||
"build-typings": "echo 'skipping..'", | ||
"post-build-typings": "echo 'skipping..'", | ||
"check-typings": "echo 'skipping..'", | ||
"check-typings-coverage": "echo 'skipping..'", | ||
"test": "jest" | ||
}, | ||
"jest": { | ||
"testEnvironment": "node" | ||
} | ||
} |
@@ -34,25 +34,1 @@ # Webpack config for Flarum JS/TS compilation | ||
For details about this, see the [`flarum/flarum-tsconfig` repository](https://github.com/flarum/flarum-tsconfig) | ||
## Options | ||
### `useExtensions` | ||
`Array<string>`, defaults to `[]`. | ||
An array of extensions whose modules should be made available. This is a shortcut to add [`externals`](https://webpack.js.org/configuration/externals/) configuration for extension modules. Imported extension modules will not be bundled, but will instead refer to the extension's exports included in the Flarum runtime (ie. `flarum.extensions["vendor/package"]`). | ||
For example, to access the Tags extension module within your extension: | ||
**forum.js** | ||
```js | ||
import { Tag } from '@flarum/tags/forum'; | ||
``` | ||
**webpack.config.js** | ||
```js | ||
module.exports = config({ | ||
useExtensions: ['flarum/tags'], | ||
}); | ||
``` |
Sorry, the diff of this file is not supported yet
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
Dynamic require
Supply chain riskDynamic require can indicate the package is performing dangerous or unsafe dynamic code execution.
Found 1 instance in 1 package
22
Yes
32639
17
5
685
34
10
1
+ Addedloader-utils@^1.4.0
+ Addedschema-utils@^3.0.0
+ Addedbabel-loader@9.2.1(transitive)
+ Addedcommon-path-prefix@3.0.0(transitive)
+ Addedfind-cache-dir@4.0.0(transitive)
+ Addedfind-up@6.3.0(transitive)
+ Addedjson5@1.0.2(transitive)
+ Addedloader-utils@1.4.2(transitive)
+ Addedlocate-path@7.2.0(transitive)
+ Addedminimist@1.2.8(transitive)
+ Addedp-limit@4.0.0(transitive)
+ Addedp-locate@6.0.0(transitive)
+ Addedpath-exists@5.0.0(transitive)
+ Addedpkg-dir@7.0.0(transitive)
+ Addedschema-utils@3.3.0(transitive)
+ Addedyocto-queue@1.1.1(transitive)
- Removedbabel-loader@8.4.1(transitive)
- Removedcommondir@1.0.1(transitive)
- Removedfind-cache-dir@3.3.2(transitive)
- Removedfind-up@4.1.0(transitive)
- Removedloader-utils@2.0.4(transitive)
- Removedlocate-path@5.0.0(transitive)
- Removedmake-dir@3.1.0(transitive)
- Removedp-limit@2.3.0(transitive)
- Removedp-locate@4.1.0(transitive)
- Removedp-try@2.2.0(transitive)
- Removedpath-exists@4.0.0(transitive)
- Removedpkg-dir@4.2.0(transitive)
- Removedschema-utils@2.7.1(transitive)
Updated@babel/core@^7.20.2
Updated@babel/preset-env@^7.20.2
Updated@babel/preset-react@^7.18.6
Updated@babel/runtime@^7.20.1
Updatedbabel-loader@^9.1.0
Updatedtypescript@^4.9.3