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

Not working with webpack alias #144

Open
nataliazanolli opened this issue Oct 25, 2018 · 1 comment
Open

Not working with webpack alias #144

nataliazanolli opened this issue Oct 25, 2018 · 1 comment

Comments

@nataliazanolli
Copy link

Hi, I install now the package flow-ide, and when I import the type flow like:

import type { Acao } from 'BPMTypes/Instancia';

it's not working, only work when I import like:

import type { Acao } from '../../types/Instancia';

I'm using the alias of webpack:

module.exports = { resolve: { alias: { 'BPMTypes': path.resolve(__dirname, '../src/bpm/types'), }, }, };

@nataliazanolli nataliazanolli changed the title Not working with wepack alias Not working with webpack alias Oct 25, 2018
@amuino
Copy link

amuino commented Nov 15, 2018

FYI: you can solve this by configuring the alias mapping in your .flowconfing [options] section:

https://flow.org/en/docs/config/options/#toc-module-name-mapper-regex-string

[options]
module.name_mapper='^SomeAlias/' ->'<PROJECT_ROOT>/vendor/some/other/path/'

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

No branches or pull requests

2 participants