Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Jul 07 06:45

    dependabot[bot] on npm_and_yarn

    (compare)

  • Jul 07 06:45
    dependabot[bot] closed #171
  • Jul 07 06:45
    dependabot[bot] commented #171
  • Jul 07 06:45
    dependabot[bot] labeled #172
  • Jul 07 06:45
    dependabot[bot] opened #172
  • Jul 07 06:45

    dependabot[bot] on npm_and_yarn

    build(deps): bump moment from 2… (compare)

  • Apr 09 02:14
    dependabot[bot] labeled #171
  • Apr 09 02:14
    dependabot[bot] opened #171
  • Apr 09 02:14

    dependabot[bot] on npm_and_yarn

    build(deps): bump moment from 2… (compare)

  • Jan 15 04:43
    dependabot[bot] labeled #170
  • Jan 15 04:43
    dependabot[bot] opened #170
  • Jan 15 04:43

    dependabot[bot] on npm_and_yarn

    build(deps): bump shelljs from … (compare)

  • Jan 15 01:38
    dependabot[bot] labeled #169
  • Jan 15 01:38
    dependabot[bot] opened #169
  • Jan 15 01:38

    dependabot[bot] on npm_and_yarn

    build(deps): bump marked from 0… (compare)

  • Aug 11 2021 04:06
    dependabot[bot] labeled #168
  • Aug 11 2021 04:06
    dependabot[bot] opened #168
  • Aug 11 2021 04:06

    dependabot[bot] on npm_and_yarn

    build(deps): bump path-parse fr… (compare)

  • May 10 2021 16:48
    dependabot[bot] labeled #167
  • May 10 2021 16:48
    dependabot[bot] opened #167
lostintime
@lostintime
no need for permission for now
btw - funfix packages are kinda fat .. because of documentation
is there any reason to keep it there?
ex: 11M node_modules/funfix-types/
9.8M node_modules/funfix-types/dist/docs/
Alexandru Nedelcu
@alexandru
Hmm, yeah, not good.
The packages are meant to be minified, but yeah, maybe we should not package the docs.
lostintime
@lostintime
in some projects (servers) we’re not using webpack or something, just packaging prod dependencies to docker image, so it adds to final size
Alexandru Nedelcu
@alexandru
OK, will work on removing the docs from the package.
Alexandru Nedelcu
@alexandru

@/all I released the initial version of https://funland-js.org

This is the replacement for funfix-types. It's a refactoring, the types are plain interfaces with no code, compatible with static-land and the higher-kinded encoding is also compatible with fp-ts. And the laws are provided as a separate project, because size matters.

And then this is going to be a dependency for all of funfix's sub-projects, so all data types are going to be compatible with the static-land spec by default.

Alexandru Nedelcu
@alexandru
I also pushed a dummy at https://www.npmjs.com/package/monix
Alvaro Carrasco
@alvaroc1
@alexandru ha awesome :D
Alexandru Nedelcu
@alexandru

@/all Released a new Funfix version: https://github.com/funfix/funfix/releases/tag/v7.0.0-rc.2

It’s a pre-release, with breaking changes, exports its “types” sub-project into https://funland-js.org; the theme of the release being compatibility with static-land, Fantasy-Land and reuses the HTKs encoding of fp-ts.

Alexandru Nedelcu
@alexandru

@lostintime here's the latest release candidate:

$ du -h node_modules
884K    node_modules/funfix-exec/dist
176K    node_modules/funfix-exec/src
1.1M    node_modules/funfix-exec
176K    node_modules/funland/dist
 72K    node_modules/funland/src
264K    node_modules/funland
492K    node_modules/funfix-core/dist
108K    node_modules/funfix-core/src
616K    node_modules/funfix-core
612K    node_modules/funfix-effect/dist
120K    node_modules/funfix-effect/src
748K    node_modules/funfix-effect
 48K    node_modules/funfix/dist
8.0K    node_modules/funfix/src
 68K    node_modules/funfix
2.7M    node_modules

So docs are gone from the packages.

lostintime
@lostintime
@alexandru Thanks!
Alvaro Carrasco
@alvaroc1
i'm not very familiar with frontend packaging... i noticed that in our node_modules/funfix/dist directory there's individual js files like future.js, cancelable.js, etc... and also a es5.js that seems to contains ES5 versions of all of it...
we're importing like this: import { Future } from 'funfix';
but we're getting syntax errors on IE11... it seems like the ES6 code with class Future ... is making it to the browser...
IE6 doesn't support that syntax, so I am guessing I need to somehow make use of the es5.js files in the dist folder, but not sure how
we're using webpack, any ideas?
how do i make webpack load the ES5 js files instead of the ES6 ones?
Alvaro Carrasco
@alvaroc1
ah figured it out: added "es5module" to the resolve.mainFields webpack config
Alexandru Nedelcu
@alexandru
@alvaroc1 the es5 module was prepared for Webpack, as it has ES5 code, but with ES2015 modules. If you’re doing “import” statements and letting Webpack handle it, then that’s what you need.
Alexandru Nedelcu
@alexandru
For the browser there’s also the normal UMD module, indicated in package.json via “main”. But that one requires manual script tags, being meant for builds that don’t use ES2015 modules.
Alvaro Carrasco
@alvaroc1
a bit off-topic, but i'm trying to compare custom types in javascript... funfix-core has IEquals, but just that... any suggestions to where I should look? Should I be looking for implementations of fantasyland's Ord?
Alexandru Nedelcu
@alexandru
@alvaroc1 funfix-core also has the is function, which does use IEquals if it sees that the type implements it, or valueOf.
It's not very original either, it's what other libraries like immutable.js are doing as well.
Oh, you meant that you want ordering?
Alvaro Carrasco
@alvaroc1
yeah, sorry should have specified ordering
Alexandru Nedelcu
@alexandru
Somebody just committed Ord to funland. Not sure how much that helps — funfix/funland#12
Alvaro Carrasco
@alvaroc1
i REALLY miss typeclasses when I stray from scala :/
Alexandru Nedelcu
@alexandru
Right. Well the problem with Ord is that I'm not sure if there's any common protocol.
The closest you can get is to compare the output of valueOf() btw.
Alvaro Carrasco
@alvaroc1
ah good pointer, i didn't know about valueOf
but [...].sort() won't use that by default, right? I still have to give it an explicit comparison function?
Alexandru Nedelcu
@alexandru
@alvaroc1 I have no idea what the standard sort() uses, but it's a good chance that it uses valueOf(). Try it out.
Alvaro Carrasco
@alvaroc1
will do, thanks
Iván Portilla
@Ivykp
Hey guys, i hope you are fine today. I have a little question: i am trying to use phantomjs with angular-cli for headless testing, i configured everything but i have a problem with a library i am using: https://github.com/funfix/funfix. When i run ng test i receive the next error: PhantomJS 2.1.1 (Mac OS X 0.0.0) ERROR { "message": "SyntaxError: Use of reserved word 'class'\nat http://localhost:9876/_karma_webpack_/vendor.bundle.js:95636:0", "str": "SyntaxError: Use of reserved word 'class'\nat http://localhost:9876/_karma_webpack_/vendor.bundle.js:95636:0" }
Any idea what can i do?
Alexandru Nedelcu
@alexandru
@Ivykp how are you importing funfix into your project?
And are you using Webpack?
Funfix should work out of the box either with ES2015 or with CommonJS. However there's a catch — if you're using Webpack, then know that Webpack has an implemention that supports ES2015 modules, but NOT other ES2015 features.
So what you need to do is to work with import "funfix/dist/es5"
So the funfix/dist/es5 package is specifically prepared for usage with Webpack and similar.
Hope this helps.
David Dudson
@DavidDudson

@alexandru Would you be interested in having .map2 etc. added to Option in funfix.

I quite often find myself having 2 or more inputs that need to be sanitized before using them.

Unless I'm missing an easier way to do the following

optA.map2(optB, (a, b) => a + b)
David Dudson
@DavidDudson
Nevermind. im blind, I just found the static methods
Alexandru Nedelcu
@alexandru
:+1:
Frank Filho
@frankpf
How do I convert a function that returns Promise<T> to a function returning IO<T>?
Alvaro Carrasco
@alvaroc1
maybe IO.deferFuture(() => Future.fromPromise( doSuff() )) not sure though... just a guess