-
Notifications
You must be signed in to change notification settings - Fork 51
feat(docs): add loaders and plugins index pages #153
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
ryzrr
wants to merge
2
commits into
main
Choose a base branch
from
feat/loaders-plugins-index
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+103
−4
Open
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 hidden or 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 hidden or 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,59 @@ | ||
| --- | ||
| authors: simon04,bajras,rhys-vdw,EugeneHlushko,hemal7735,snitin315,anshumanv,jamesgeorge007,chenxsan | ||
| --- | ||
|
|
||
| # Loaders | ||
|
|
||
| Webpack enables use of [loaders](#TODO[/concepts/loaders]) to preprocess files. This allows you to bundle any static resource way beyond JavaScript. You can easily write your own loaders using Node.js. | ||
| Loaders are separate packages that extend webpack's capabilities and are maintained within the broader ecosystem. | ||
| Loaders are activated by using `loadername!` prefixes in `import .. from "mod";`/`require()` statements, or are automatically applied via regex from your webpack configuration – see [configuration](#TODO[/concepts/loaders/#configuration]). | ||
|
|
||
| ## Files | ||
|
|
||
| - [`ref-loader`](https://www.npmjs.com/package/ref-loader) Create dependencies between any files manually | ||
|
|
||
| ## JSON | ||
|
|
||
| - [`cson-loader`](https://github.com/awnist/cson-loader) Loads and transpiles a [CSON](https://github.com/bevry/cson#what-is-cson) file | ||
|
|
||
| ## Transpiling | ||
|
|
||
| - [`babel-loader`](https://github.com/babel/babel-loader) Loads ES2015+ code and transpiles to ES5 using [Babel](https://babeljs.io/) | ||
| - [`esbuild-loader`](https://github.com/privatenumber/esbuild-loader) Loads ES2015+ code and transpiles to ES6+ using [esbuild](https://esbuild.github.io/) | ||
| - [`buble-loader`](https://github.com/sairion/buble-loader) Loads ES2015+ code and transpiles to ES5 using [Bublé](https://buble.surge.sh/guide/) | ||
| - [`traceur-loader`](https://github.com/jupl/traceur-loader) Loads ES2015+ code and transpiles to ES5 using [Traceur](https://github.com/google/traceur-compiler#readme) | ||
| - [`ts-loader`](https://github.com/TypeStrong/ts-loader) Loads [TypeScript](https://www.typescriptlang.org/) 2.0+ like JavaScript | ||
| - [`coffee-loader`](/docs/loaders/coffee-loader) Loads [CoffeeScript](http://coffeescript.org/) like JavaScript | ||
| - [`fengari-loader`](https://github.com/fengari-lua/fengari-loader/) Loads Lua code using [fengari](https://fengari.io/) | ||
| - [`elm-webpack-loader`](https://github.com/elm-community/elm-webpack-loader) Loads [Elm](https://elm-lang.org/) like JavaScript | ||
|
|
||
| ## Templating | ||
|
|
||
| - [`html-loader`](/docs/loaders/html-loader) Exports HTML as string, require references to static resources | ||
| - [`pug-loader`](https://github.com/pugjs/pug-loader) Loads Pug and Jade templates and returns a function | ||
| - [`markdown-loader`](https://github.com/peerigon/markdown-loader) Compiles Markdown to HTML | ||
| - [`react-markdown-loader`](https://github.com/javiercf/react-markdown-loader) Compiles Markdown to a React Component using the markdown-parse parser | ||
| - [`posthtml-loader`](https://github.com/posthtml/posthtml-loader) Loads and transforms a HTML file using [PostHTML](https://github.com/posthtml/posthtml) | ||
| - [`handlebars-loader`](https://github.com/pcardune/handlebars-loader) Compiles Handlebars to HTML | ||
| - [`markup-inline-loader`](https://github.com/asnowwolf/markup-inline-loader) Inline SVG/MathML files to HTML. It's useful when applying icon font or applying CSS animation to SVG. | ||
| - [`twig-loader`](https://github.com/zimmo-be/twig-loader) Compiles Twig templates and returns a function | ||
| - [`remark-loader`](https://github.com/webpack/remark-loader) Load markdown through `remark` with built-in image resolution | ||
|
|
||
| ## Styling | ||
|
|
||
| - [`style-loader`](/docs/loaders/style-loader) Add exports of a module as style to DOM | ||
| - [`css-loader`](/docs/loaders/css-loader) Loads CSS file with resolved imports and returns CSS code | ||
| - [`css-utility-loader`](https://github.com/SahilKhanWDC/css-utility-loader-webpack-.git) - Automatically parses and translates legacy CSS properties into modern utility classes (Tailwind) at build-time. | ||
| - [`less-loader`](/docs/loaders/less-loader) Loads and compiles a LESS file | ||
| - [`sass-loader`](/docs/loaders/sass-loader) Loads and compiles a SASS/SCSS file | ||
| - [`postcss-loader`](/docs/loaders/postcss-loader) Loads and transforms a CSS/SSS file using [PostCSS](http://postcss.org) | ||
| - [`stylus-loader`](/docs/loaders/stylus-loader) Loads and compiles a Stylus file | ||
|
|
||
| ## Frameworks | ||
|
|
||
| - [`vue-loader`](https://github.com/vuejs/vue-loader) Loads and compiles [Vue Components](https://vuejs.org/v2/guide/components.html) | ||
| - [`angular2-template-loader`](https://github.com/TheLarkInn/angular2-template-loader) Loads and compiles [Angular](https://angular.io/) Components | ||
|
|
||
| ## Awesome | ||
|
|
||
| For more third-party loaders, see the list from [awesome-webpack](https://github.com/webpack-contrib/awesome-webpack#loaders). |
This file contains hidden or 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,36 @@ | ||
| --- | ||
| authors: simon04,gonzoyumo,rouzbeh84,aretecode,eko3alpha,refactorized,byzyk,EugeneHlushko,snitin315,chenxsan | ||
| --- | ||
|
|
||
| # Plugins | ||
|
|
||
| Webpack has a rich plugin interface. Most of the features within webpack itself use this plugin interface. This makes webpack **flexible**. | ||
|
|
||
| | Name | Description | | ||
| | --------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------- | | ||
| | [`BannerPlugin`](/docs/api/v5.x/plugins/BannerPlugin) | Add a banner to the top of each generated chunk | | ||
| | [`ChunksWebpackPlugin`](https://www.npmjs.com/package/chunks-webpack-plugin) | Create HTML files with entrypoints and chunks relations to serve your bundles | | ||
| | [`CompressionWebpackPlugin`](/docs/plugins/compression-webpack-plugin) | Prepare compressed versions of assets to serve them with Content-Encoding | | ||
| | [`ContextReplacementPlugin`](/docs/api/v5.x/plugins/ContextReplacementPlugin) | Override the inferred context of a `require` expression | | ||
| | [`CopyWebpackPlugin`](/docs/plugins/copy-webpack-plugin) | Copies individual files or entire directories to the build directory | | ||
| | [`DefinePlugin`](/docs/api/v5.x/plugins/DefinePlugin) | Allow global constants configured at compile time | | ||
| | [`DllPlugin`](/docs/api/v5.x/plugins/DllPlugin) | Split bundles in order to drastically improve build time | | ||
| | [`EnvironmentPlugin`](/docs/api/v5.x/plugins/EnvironmentPlugin) | Shorthand for using the [`DefinePlugin`](/docs/api/v5.x/plugins/DefinePlugin) on `process.env` keys | | ||
| | [`EslintWebpackPlugin`](/docs/plugins/eslint-webpack-plugin) | A ESLint plugin for webpack | | ||
| | [`HotModuleReplacementPlugin`](/docs/api/v5.x/plugins/HotModuleReplacementPlugin) | Enable Hot Module Replacement (HMR) | | ||
| | [`HtmlWebpackPlugin`](https://www.npmjs.com/package/html-webpack-plugin) | Easily create HTML files to serve your bundles | | ||
| | [`IgnorePlugin`](/docs/api/v5.x/plugins/IgnorePlugin) | Exclude certain modules from bundles | | ||
| | [`LimitChunkCountPlugin`](/docs/api/v5.x/optimize/LimitChunkCountPlugin) | Set min/max limits for chunking to better control chunking | | ||
| | [`MergeDuplicateChunksPlugin`](/docs/api/v5.x/optimize/MergeDuplicateChunksPlugin) | Merge chunks that contain the same modules | | ||
| | [`MinChunkSizePlugin`](/docs/api/v5.x/optimize/MinChunkSizePlugin) | Keep chunk size above the specified limit | | ||
| | [`MiniCssExtractPlugin`](/docs/plugins/mini-css-extract-plugin) | creates a CSS file per JS file which requires CSS | | ||
| | [`NoEmitOnErrorsPlugin`](/docs/api/v5.x/plugins/NoEmitOnErrorsPlugin) | Skip the emitting phase when there are compilation errors | | ||
| | [`NormalModuleReplacementPlugin`](/docs/api/v5.x/plugins/NormalModuleReplacementPlugin) | Replace resource(s) that matches a regexp | | ||
| | [`ProgressPlugin`](/docs/api/v5.x/plugins/ProgressPlugin) | Report compilation progress | | ||
| | [`ProvidePlugin`](/docs/api/v5.x/plugins/ProvidePlugin) | Use modules without having to use import/require | | ||
| | [`SourceMapDevToolPlugin`](/docs/api/v5.x/plugins/SourceMapDevToolPlugin) | Enables a more fine grained control of source maps | | ||
| | [`EvalSourceMapDevToolPlugin`](/docs/api/v5.x/plugins/EvalSourceMapDevToolPlugin) | Enables a more fine grained control of eval source maps | | ||
| | [`SvgChunkWebpackPlugin`](https://www.npmjs.com/package/svg-chunk-webpack-plugin) | Generate SVG sprites optimized by SVGO based on your entry point dependencies | | ||
| | [`MinimizerPlugin`](/docs/plugins/minimizer-webpack-plugin) | Uses Terser (or other) to minify the JS/CSS/HTML/JSON/etc in your project | | ||
|
|
||
| For more third-party plugins, see the list from [awesome-webpack](https://github.com/webpack-contrib/awesome-webpack#webpack-plugins). | ||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
Let's remove this line, we are still working on a new home for these