Error: Cannot find module 'svg-baker-runtime/symbol'
See original GitHub issueDo you want to request a feature, report a bug or ask a question? Ask a question
What is the current behavior? Error: Cannot find module ‘svg-baker-runtime/symbol’
I have submodule (kit for component) and main project. I tested svg-sprite-loader in kit and it was ok. Then I added this rules to main project ( https://gist.github.com/pSHCH/cb03ff5469df85439f4fe42969430330 ).
My component in kit:
import React from 'react';
import user from './img/user.svg';
var svg = {
user
};
function Icon(props) {
return <i>
<svg className={st['icon-path']} viewBox={svg[props.type].viewBox}>
<use xlinkHref={'#${svg[props.type].id}'}/>
</svg>
</i>;
}
export default Icon;
and use at page:
<Icon type='user'/>
What is the expected behavior?
If the current behavior is a bug, please provide the steps to reproduce, at least part of webpack config with loader configuration and piece of your code. The best way is to create repo with minimal setup to demonstrate a problem (package.json, webpack config and your code). It you don’t want to create a repository - create a gist with multiple files
If this is a feature request, what is motivation or use case for changing the behavior?
Please tell us about your environment:
- Node.js version: 7.4.0
- webpack version: 2.2.0
- svg-sprite-loader version: 3.2.4
- OS type & version: OS X El Capitan
Other information (e.g. detailed explanation, stacktraces, related issues, suggestions how to fix, links for us to have context, eg. stackoverflow, gitter, etc)
Issue Analytics
- State:
- Created 6 years ago
- Reactions:1
- Comments:25 (11 by maintainers)
Top GitHub Comments
Was facing this issue with version
4.1.6
. Downgraded this to version4.1.3
and it’s gone. Config I used:@kisenka Thank you! Here’s the repo.
You can bootstrap it like this:
To run the project: