jonespen / kss-webpack-plugin

Generate KSS styleguide from Webpack
MIT License
10 stars 10 forks source link

Add option to set assetPath with chunks-option #15

Closed stephfh closed 3 years ago

stephfh commented 3 years ago

Since asset loading was hardcoded to always be included from the respective project root, I added an option to allow the path to the assets to be set in the KssPlugin config object inside webpack.config.js

Like so:

const KssConfig = {
  source: './src/scss',
  chunks: ['app', 'some', 'chunk'],
  assetPath: 'path/to/your/compiled/assets/',
};
jonespen commented 3 years ago

Thanks! I haven’t used this project in years, but this change looks good to me :)

stephfh commented 3 years ago

Hi @jonespen,

could you tag the version of the package on npm as well?

Seeing that the package itself hasn't been bumped after the merge of #13 as well, and thus is still using the 1.5.0 tag from 2019. That would be great, so I don't have to switch to the master branch as a source in the project's package.json, and can use the tag (as intended). :)

jonespen commented 3 years ago

Ah sorry, thanks for the heads up! Published a new version now. It might take some time before NPM web is updated, but v1.6.0 should be released:

➜  kss-webpack-plugin git:(master) npm show kss-webpack-plugin

kss-webpack-plugin@1.6.0 | MIT | deps: 1 | versions: 10
KSS Webpack plugin ===================
https://github.com/jonespen/kss-webpack-plugin#readme

dist
.tarball: https://registry.npmjs.org/kss-webpack-plugin/-/kss-webpack-plugin-1.6.0.tgz
.shasum: 7b4ab9953f6b1be820d379b4731250c8efea1fa9
.integrity: sha512-wx2584qyLf/Y2U3fMPGNE4jr8lRHCSBDCTU0481beQ4PJsIodu7sURMjA6fh+ClGcmNUtMvRZzZKH+oaTGeZFA==
.unpackedSize: 6.0 kB

dependencies:
kss: ^3.0.0 || ^3.0.0-beta.14 

maintainers:
- jonespen <jonespen@gmail.com>
- davecranwell <dave@davecranwell.com>

dist-tags:
latest: 1.6.0  

published 3 minutes ago by jonespen <jonespen@gmail.com>