We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
npm install -D babel-plugin-module-resolver
설치하고, package.json 이나 .babelrc 에 아래 내용 추가
package.json
.babelrc
"plugins": [ ["module-resolver", { "root": ["./src"], "alias": { "test": "./test", "underscore": "lodash" } }] ]
alias는 나는 안 썼지만, 웹 검색할때 있던 예제를 그대로 가져오느라.. 기본적으로는 root 만 잘 지정하면, BaseUrl을 지정된다.
root
위처럼 적용하고 babel 컴파일하면, 소스코드에 절대경로로 입력했던 친구들이 다 상대경로로 바뀌어서 컴파일된다.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
설치하고,
package.json
이나.babelrc
에 아래 내용 추가alias는 나는 안 썼지만, 웹 검색할때 있던 예제를 그대로 가져오느라..
기본적으로는
root
만 잘 지정하면, BaseUrl을 지정된다.위처럼 적용하고 babel 컴파일하면, 소스코드에 절대경로로 입력했던 친구들이 다 상대경로로 바뀌어서 컴파일된다.
The text was updated successfully, but these errors were encountered: