Comments (7)
The issue I see is that Crockford's base32 is intended to be written in uppercase, so a lowercase form of ULID (LULID?) would be better served by a different encoding such as z-base-32.
from javascript.
When decoding, upper and lower case letters are accepted
So an ulid decoder should support upper and lower case anyways ...
from javascript.
You're right – it turns out ULID is already specified as case-insensitive. Are you proposing changing the default or just making it configurable? Your original comment contradicts the issue title.
from javascript.
Sry for the unclear wording 😅. I just want it to be configurable. The default should probably remain upper case, as this also seems to be what crockford uses as default.
from javascript.
I'm open to outputting/formatting as lower-case, since the spec is case-insensitive. If you'd like to submit a PR, I'd be happy to accept it.
from javascript.
Created a PR: #34
from javascript.
@adius, on reflection, I have decided that I will not be accepting this PR. The alternative is incredibly simple, and what we would use internally to make a ULID lowercase, so I would recommend for you to it instead:
ulid().toLowerCase()
from javascript.
Related Issues (20)
- isUlid
- dist _index.js#L59
- License violation HOT 20
- Where is ulid.js HOT 3
- Support for RFC 4648 base32? HOT 2
- First and Last IDs for Timestamp HOT 4
- Is there a way to get the timestamp from a given ULID? HOT 3
- PRNG inconsistency HOT 1
- Crypto API isn't detected on alternative platforms HOT 5
- Monotonically Increasing Guarantee
- is_ulid(x) HOT 3
- Generate time from shortened ulid?
- Random bias?
- Not available in web workers
- Maintainers HOT 4
- Please Upgrade Your Package HOT 1
- Error in worker HOT 2
- issue 1
- issue2
- Decoding ULID string into bytes HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from javascript.