Nearsighted Prank Master

    simple-svg-loader

    1.2.4 • Public • Published

    simple-svg-loader

    config:

    var webpack = require('webpack');
     
    module.exports = {
        module: {
            rules: [
                {
                    test: /\.svg$/,
                    loader: 'simple-svg-loader'
                }
            ]
        }
    };

    use:

    import './icons/home.svg';
    <a href="/">
        <svg viewBox="0 0 32 32"><use xlink:href="#home"></use></svg>
        Home
    </a>

    change id:

    import './icons/home.svg?id=icon-home';
    <svg viewBox="0 0 32 32"><use xlink:href="#icon-home"></use></svg>

    Keywords

    none

    Install

    npm i simple-svg-loader

    DownloadsWeekly Downloads

    1

    Version

    1.2.4

    License

    MIT

    Last publish

    Collaborators

    • riim