Skip to content
This repository has been archived by the owner on Mar 17, 2021. It is now read-only.

Allow access to [parent] variable #52

Closed
natew opened this issue Jan 5, 2016 · 2 comments
Closed

Allow access to [parent] variable #52

natew opened this issue Jan 5, 2016 · 2 comments

Comments

@natew
Copy link

natew commented Jan 5, 2016

I'd really want access to the name of the parent require. So if I require a module bootstrap and it does:

require('abc.css')

I can then control the output of that file and have it be:

somedir/bootstrap/abc.css

I'd imagine it's something like:

?name=somedir/[parent]/[name].css

@natew
Copy link
Author

natew commented Jan 5, 2016

Another thing that would be helpful is naming based on the parent file as well as parent module. So maybe:

  • [parentFile]
  • [parentModule]

@alexander-akait
Copy link
Member

alexander-akait commented Jun 30, 2017

@natew we use https://github.com/webpack/loader-utils#interpolatename for interpolate filename. What mean parent*? How we can determinate parent?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants