Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add an alias from '@' to src #426

Merged
merged 2 commits into from
Jun 7, 2017
Merged

Add an alias from '@' to src #426

merged 2 commits into from
Jun 7, 2017

Conversation

posva
Copy link
Member

@posva posva commented Apr 1, 2017

Closes #422
This makes it easier to combine with the official webpack template

Closes vuejs#422
This makes it easier to combine with the official webpack template
@posva posva requested a review from egoist April 1, 2017 11:53
bin/vue-build Outdated
@@ -150,7 +150,9 @@ var webpackConfig = {
cwd('node_modules'), // modules in cwd's node_modules
ownDir('node_modules') // modules in package's node_modules
],
alias: {}
alias: {
'@': 'src'
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should use absolute path? like cwd('src')

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it better? I also wondered but since this worked I didn't add anything

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We use an absolute path for this alias in the webpack template as well:

https://github.com/vuejs-templates/webpack/blob/master/template/build/webpack.base.conf.js#L27

/ping @posva

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Forgot about this!

@LinusBorg
Copy link
Member

/ping @egoist

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

Successfully merging this pull request may close these issues.

None yet

3 participants