-
-
Notifications
You must be signed in to change notification settings - Fork 1
Failed to compile for flutter web. int64MaxValue #30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Could you please provide more context? A reproducible code may be? |
https://dart.dev/resources/language/number-representation
...
late Nitrite _db;
late NitriteCollection _collection;
...
_db = await Nitrite.builder().openOrCreate();
_collection = await _db.getCollection("resources");
...
final doc = documentFromMap(data);
final res = await _collection.updateOne(doc, insertIfAbsent: true);
return doc.id.idValue;
...
|
I have never tested it on web, I'll take a look and let you know. |
uhum... the keys in indexeddb behind the hive db on the web should not work either, for the same reason. Is ID with Snowflake too coupled? Or should it be easy to turn into a provider, to work with different ID mechanisms? |
Failed to compile for flutter web.
Error: The integer literal ... can't be represented exactly in JavaScript.
Try changing the literal to something that can be represented in JavaScript. In JavaScript .... is the closest value that can be represented exactly.
const int int64MaxValue = ...;
The text was updated successfully, but these errors were encountered: