question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Fable.Import from multiple files

See original GitHub issue

As mentioned in one of my previous comments. It would be great to import from multiple files.

As people are moving more towards Typescript, it is becoming easier to use libraries because of index.d.ts. And authors are also using this to keep d.ts file small. So, for typescript it is non-issue. But it is for us as we are converting things from them. I have created gist for Flatpickr latest version 4.x at https://gist.github.com/kunjee17/761f3ffeabd6c9abc04e89a148b8a67c . It do have index.d.ts file but as you can see it only have exposing gobal variables. And complete type definition at @types/flatpickr is still at 3.x version.

It would be great if can parse whole index.d.ts instead of only file.

Hope I make sense.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:9 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
ctaggartcommented, Nov 15, 2017

Also try it with regular .ts files.

1reaction
ctaggartcommented, Nov 16, 2017

I’m marking this complete for 0.3.0. It is more experimental. It “works” but namesapces fixes are not taken into account. I’ll address that after 0.3.0.

Read more comments on GitHub >

github_iconTop Results From Across the Web

import from multiple linked files #128 - fable-compiler/ts2fable
What is currently working is importing from single declaration files. This enabled Node, TypeScript, VSCode and many other libraries. More and ...
Read more >
How to open Modules from other files in Fable-F# - ...
I'm brand new to Fable and I'm having some issues opening a custom module from a different file. Here's my basic file setup...
Read more >
Supported Import Formats - Fable Help Center
Fable currently supports importing: ✓ Image files (PNG, JPG). ✓ Vector files (SVG, pasting directly from Illustrator).
Read more >
The project file
An important thing to note is Fable will translate F# source files to ES2015 modules using JS import . This means that files...
Read more >
F# Interop with Javascript in Fable: The Complete Guide
The first argument for import is what value you want to import, in this case it is the function parseJson and the second...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found