Skip to content

Instantly share code, notes, and snippets.

@fatihdgn fatihdgn/webpack.config.js Secret
Last active May 30, 2019

Embed
What would you like to do?
Create an Angular Component Library w/ StoryBook - Section II
const path = require('path');
const includePath = path.resolve(__dirname, '..')
module.exports = {
module: {
rules: [
{
test: [/\.stories\.tsx?$/, /index\.ts$/],
loaders: [
{
loader: require.resolve('@storybook/addon-storysource/loader'),
options: {
parser: 'typescript'
}
}
],
include: [path.resolve(__dirname, '../src')],
enforce: 'pre'
},
{
test: /\.css$/,
include: includePath,
use: ['to-string-loader', 'css-loader']
}
]
}
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.