Prolucid / fable-import-momentjs

Other
6 stars 6 forks source link

Fable 1.x bindings #1

Open et1975 opened 7 years ago

bentayloruk commented 7 years ago

I was just looking at using these bindings. Does this issue mean that the current bindings on NPM don't work with Fable 1.x?

2sComplement commented 7 years ago

Good question. The biggest change for bindings moving to Fable 1.x was the removal of the KeyValueList attribute, which I don't believe is used in these bindings. So they may work, unless @et1975 knows of another reason why they wouldn't.

et1975 commented 7 years ago

Fable 1.1 splits browser bindings out as well, but it looks we don't use those either. It just might work, but we won't know till we try. Nuget packaging would be nice to have (until then one would have install it via yarn and link the project by hand, from node_modules).

bentayloruk commented 7 years ago

Great, thank you both.

When you say to link the project by hand, do you mean copy Fable.Helpers.Moment.fs and Fable.Import.Moment.fs into the project src? I'm using the Elmish scaffold. Sorry for the basic question, but I'm not fully up to speed on how this all hangs together. Hoping to get there soon, so I can contrib back.

2sComplement commented 7 years ago

Once the npm package is installed you can add the .fs files as links and Fable will try compile them.