@aptray/file-content-loader
v1.0.2
Published
the file raw content loader. You can also use [raw-loader]
Downloads
4
Maintainers
Readme
@aptray/file-content-loader
The file raw content loader. You can also use [raw-loader]
Since the module was only published in private service at the earliest, the module with the same name will appear on the official website later, resulting in problems in internal download, so a scope version will be released.
You can also use the file-rawtxt-loader module directly.
description
💿 Installation
npm install --save-dev @aptray/file-content-loader
📖 Usage
webpack.config.js
- 🔧 simple use
// webpack 1
loaders: [
{ test: /\.txt$/, loader: "@aptray/file-content-loader" }
]
// webpack 2
rules: [
{ test: /\.txt$/, use: '@aptray/file-content-loader'}
]
- 🔧 inline use
var fileContent = require("@aptray/file-content-loader!./file.txt");
// => returns file.txt content as string
var jsContent = require("@aptray/file-content-loader!./file.js");
// => returns file.js content as string
💎 author
ilex.h
Similar projects
file-rawtxt-loader text-loader raw-loader
License
MIT
changelog
file-content-loader
于20171010 18:56
创建于私服。- 20200721 09:20 发布更新包
- 20210606 更名为
@aptray/file-content-loader
, 同时发布与 npm 官方服务。