xstream icon indicating copy to clipboard operation
xstream copied to clipboard

dist for extras

Open octavioturra opened this issue 8 years ago • 3 comments

Hey guys, can you help me?

Dist and Minify tool do not have targets for extras, so we cannot use it in JSBin, for example.

Is this intentional or you've missed to configure?

octavioturra avatar Apr 14 '17 23:04 octavioturra

I had wanted to use xstream in a browser environment from a cdn but ended up going with Bacon after discovering xstream does not offer extras as part of its dist. The project really depended on fromEvent and I didn't want to re-implement it.

What's involved in fixing this? I'm wrapping up a project this month and may be able to draft a PR in early April.

jaidetree avatar Mar 20 '19 18:03 jaidetree

Thanks for wanting to fix this! :) The work involved would be adding some npm scripts to build each extra file separately to the core: https://github.com/staltz/xstream/blob/152633f014dd62ed7777c61770b53d886d09b7e2/package.json#L24

staltz avatar Mar 27 '19 08:03 staltz

Great, I think I can handle that!

Questions:

  • Should the extras build modify the global XStream prototype or should it be like static functions to import and use directly?
  • Any interest in using XStream to form its own build tools? If we can make a node-stream adapter function for extras we could probably use it to power the build tools itself since browserify is heavily stream based.

jaidetree avatar Apr 01 '19 16:04 jaidetree