-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Handle unresolved JS import when type is exported with the same name #923
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall this seems reasonable.
src/rules/named.js
Outdated
const wrongType = meta && meta.exportKind !== undefined && meta.exportKind !== 'value' | ||
if (wrongType) { | ||
context.report(im[key], | ||
im[key].name + ' not found in \'' + node.source.value + '\'') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should probably use a template literal
src/ExportMap.js
Outdated
case 'InterfaceDeclaration': | ||
m.namespace.set(n.declaration.id.name, captureDoc(docStyleParsers, n)) | ||
case 'InterfaceDeclaration': { | ||
const meta = captureDoc(docStyleParsers, n) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe captureDoc should set the exportKind?
There have been enough Flow issues lately that I'm tempted to have |
9b8b490
to
182b109
Compare
@Coobaha i've rebased this, and around 10 tests are failing. When i comment out your implementation changes, only 2 tests are failing. I know it's been awhile, but it'd be great to get this updated and landed :-) please mark it as ready for review once it's so. |
182b109
to
5358a57
Compare
@Coobaha im not sure why you deleted the branch; it’d be great to get this in. Can you restore and reopen it? |
@ljharb Sorry was doing github cleanup and pruning stale branches. Branch is now restored |
This was not giving any error
P.S. Some specs are failing in master?