preact-cli-svg-loader
v1.1.0
Published
Removes svg extension file-loader, url-loader and raw-loader and use preact-svg-loader to load svg file as preact components
Downloads
770
Readme
preact-cli-svg-loader
Removes svg extension from file-loader, url-loader and raw-loader and use preact-svg-loader to load svg file as preact components
Getting Started
Install it via npm:
npm install preact-cli-svg-loader
yarn:
yarn add preact-cli-svg-loader --dev
And include in your project by creating a preact.config.js
const preactCliSvgLoader = require('preact-cli-svg-loader');
export default function (config, env, helpers) {
preactCliSvgLoader(config, helpers);
}
Import your svg files as preact compoments
License
MIT