ref-loader

A webpack loader that will create dependencies between any files manually

Downloads in past

Stats

StarsIssuesVersionUpdatedCreatedSize
ref-loader
721.0.34 years ago4 years agoMinified + gzip package size for ref-loader in KB

Readme

A webpack loader that will create dependencies between any files manually
Usage
Use @ref(./anyfile.ext) in any text file will build a dependency from current file to anyfile.ext; Then it will replace @ref() markup to module result of anyfile.ext.
Example
```javascript // Webpack config const rules = {
test: /\.png$/,
use: [{ loader: 'file-loader'}]
}, {
test: /\.html$/,
use: [
{ loader: 'file-loader' },
{ loader: 'extract-loader' },
{ loader: 'ref-loader' },
]
}
; ``` ```html ``` ```javascript // index.js import './avatarpage.html' ```