webpack/examples/custom-json-modules/template.md

48 lines
515 B
Markdown
Raw Permalink Normal View History

This is a simple example that shows the usage of a custom parser for json-modules.
2019-11-29 01:12:11 +08:00
Toml, yaml and json5 files can be imported like other modules without toml-loader.
2019-11-29 01:12:11 +08:00
# data.toml
```toml
_{{data.toml}}_
```
# data.yaml
```yaml
_{{data.yaml}}_
```
2019-12-01 04:51:03 +08:00
# data.json5
```json5
2019-11-29 23:15:04 +08:00
_{{data.json5}}_
```
2019-11-29 01:12:11 +08:00
# example.js
```javascript
_{{example.js}}_
```
# webpack.config.js
```javascript
_{{webpack.config.js}}_
```
# js/output.js
```javascript
_{{dist/output.js}}_
```
# Info
## webpack output
```
_{{stdout}}_
```