-
Notifications
You must be signed in to change notification settings - Fork 12
Deprecate this library #22
Comments
I forgot about purescript/purescript-numbers#8! |
I'm in agreement with this. While JS is the main backend, I don't think we should structure libraries around it as it does make things harder for alternate backends. |
I should have asked this first before working on purescript/purescript-numbers#11. Where do we need to port things in this repo once it's deprecated? There's a couple of parts to this repo:
|
I'm not really convinced
|
Since the |
I agree with this.
If this was done, what would the name of the repo be called? |
I'd lean towards |
Sounds fine to me. How should we create the repo? Is there some template directory I can clone and update? Or should I just reuse |
Does the stuff in https://github.com/purescript-contrib/governance work for setting up new repos too? (If we're doing this in contrib as you suggested earlier). Or ask @thomashoneyman about it perhaps 🙂. |
I didn’t think of those functions as JS-specific actually; aren’t they potentially useful to anyone processing URIs? |
Yea, that tool helps set up new projects too (so long as you’ve initialized a Spago project). |
The specific behaviour implemented by the global encode/decodeURI/component is what I'm calling JS specific, since they just "do some kinda of URI encoding type thing", neither one of them encodes in a way that actually conforms to URI specs, and both of them require caveats depending on their use case: |
Now that the port PR has been merged, do we still want to create a |
I plan to implement a This at least unblocks a few libraries which can't otherwise update to 0.14.0-rc3, and it's a tiny dependency that's easy to drop if someone does get around to implementing an RFC 3986-compliant encode and decode pair without FFI. I'll make an issue on the new repository for someone to write that function and for the library to be deprecated. |
This library is a random grab bag of various functions which happen to be in the global scope in JS. I don't think it makes a huge amount of sense in the first place (we shouldn't just copy the way JS organises things), and I think it especially doesn't make sense now that alternate backends are a thing.
I think the things that this library provides could more sensibly be split into other libraries:
isNan
,isFinite
,infinity
, parsing and formatting can live in a library likepurescript-numbers
(indeed most of them already do)purescript-integers
purescript-strings
purescript-numbers
library, by clamping the format parameters).However, I think we should have functions for parsing and formatting Number values somewhere in core. So my proposal is to move things into other libraries as described above, move
numbers
into core, and then deprecate this library.@sharkdp: would moving
numbers
to core be alright with you?The text was updated successfully, but these errors were encountered: