-
Notifications
You must be signed in to change notification settings - Fork 4.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Generate plugin list file Removes the importing of all plugins in src/util/resolveConfig to avoid importing CSS. Import the built plugin list file instead. * Use `process.cwd()` instead of `__dirname` to resolve path Co-authored-by: Federico Ciardi <[email protected]> * Import core plugin list in resolveConfig test * Generate plugin list prebabelify and on install * Move generation from install to postinstall Co-authored-by: Federico Ciardi <[email protected]> Co-authored-by: Federico Ciardi <[email protected]>
- Loading branch information
1 parent
973d53d
commit c0ee520
Showing
7 changed files
with
44 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,3 +4,4 @@ | |
/peers | ||
/tests/fixtures/cli-utils.js | ||
/stubs/* | ||
/src/corePluginList.js |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -15,3 +15,6 @@ yarn-error.log | |
|
||
# Perf related files | ||
isolate*.log | ||
|
||
# Generated files | ||
/src/corePluginList.js |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -18,18 +18,20 @@ | |
"David Hemphill <[email protected]>" | ||
], | ||
"scripts": { | ||
"prebabelify": "rimraf lib", | ||
"prebabelify": "npm run generate:plugin-list && rimraf lib", | ||
"babelify": "babel src --out-dir lib --copy-files", | ||
"postbabelify": "ncc build lib/cli-peer-dependencies.js -o peers", | ||
"rebuild-fixtures": "npm run babelify && babel-node scripts/rebuildFixtures.js", | ||
"prepublishOnly": "npm install --force && npm run babelify && babel-node scripts/build.js && node scripts/build-plugins.js", | ||
"style": "eslint .", | ||
"test": "cross-env TAILWIND_MODE=build jest", | ||
"test:integrations": "npm run test --prefix ./integrations", | ||
"postinstall": "npm run generate:plugin-list", | ||
"install:integrations": "node scripts/install-integrations.js", | ||
"posttest": "npm run style", | ||
"compat": "node scripts/compat.js --prepare", | ||
"compat:restore": "node scripts/compat.js --restore" | ||
"compat:restore": "node scripts/compat.js --restore", | ||
"generate:plugin-list": "babel-node scripts/create-plugin-list.js" | ||
}, | ||
"files": [ | ||
"dist/*.css", | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
import * as corePlugins from '../src/plugins' | ||
import fs from 'fs' | ||
import path from 'path' | ||
|
||
const corePluginList = Object.keys(corePlugins) | ||
|
||
fs.writeFileSync( | ||
path.join(process.cwd(), 'src', 'corePluginList.js'), | ||
`export default ${JSON.stringify(corePluginList)}` | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
c0ee520
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Simple File List is a free plugin that is great for when you need to provide a list of files, either publicly available or private to logged-in users.