* Build out partial functionality and with methods
* Use temporal_rs's TinyAsciiStr
* Apply review feedback for specification comments
* Bump temporal-rs and add DateTime::with
* Remove leftover eprintln from JsPromise::await_blocking
* Add clippy for denying print and eprints
And remove usage of println or allow them.
* Address comment
* Add more utility functions around modules and exports
* Use import instead of path
* clippies and fmt
* clippies and fmt
* Add JsPromise::await_blocking and remove ell_and_run
* Fix documentation CI job
* Split default icu data into lazily deserialized parts
* FIx no_std compilation
* Lazily load more ICU tools
* Fix regressions and use more stable constructors
* lazy builtins
* Bump temporal_rs to latest commit
* Fix build
* Begining of plainYearMonth methods
* plainYearMonth: get_in_leap_year, get_months_in_year
* plain_year_month: implement add/subtract
* Addition of MonthDay methods
* toString implementations
* some changes to migrate to FiniteF64
* - bump the temporal version
- Move with implementation to to_temporal_month_day
- review comments
* switch to using as_inner() instead of from
Also use let _ to appease new clippy rules
* get the calendarID from the object
* update temporal ref
* Revert "lazy builtins"
This reverts commit a4e602d129.
* changes from review comments
---------
Co-authored-by: jedel1043 <jedel0124@gmail.com>
* feat: add a way to create `JsString` from ASCII literal
* chore: add todo comment to change `DUMMY_RAW_JS_STRING` to constant
* chore: make `ORIGINAL_JS_STR` a static reference to reduce binary size
* chore: replace `static` to `const` and simplify the code
* chore: add generic parameters to `transmute`
* chore: try to use union to represent
* chore: make miri happy
* Optimize const accesses for static strings
* perf: set LITERAL a constant reference to avoid duplication on data segment
* chore: add comments
* chore: add comments
* chore : fix `refcount` test
* chore: remove unnessnary assertion
* chore: modify definition of `JsString::is_static`
* chore: add more tests
* chore: mark `StaticJsString` as `repr[C]`
* chore: improve comment
* chore: Mark `TaggedLen` as `repr(transparent)`
---------
Co-authored-by: jedel1043 <jedel0124@gmail.com>
* Add a way to add setters/getters in js_class!
* Address cargo clippies
* Add new interface and update doc
* Setters can now return a value, which can be a JsResult
* Remove clippy warning
* Fix having both get and set with a return type fails to match
* Update length and builtin properties
* Split tags and names as two different statics
* Missed YearMonth and MonthDay length
* Fix length on some methods
* Missed one length
* cargo fmt
* Add a js_error! macro to create opaque errors
And as a bonus since I needed it, simplify comparison of strings
and add PartialEq<&str> for JsString.
* Add PartialEq<str> for JsStr. PartialEq<&str> uses the other
* Cargo clippy
* Remove conversion of non-string literals and remove From<String> for JsValue
* Updates to temporal_rs version and temporal methods
* Apply review feedback for relativeTo
* Forgot Date.prototype.toPlainDateTime
* Fix doc on toPlainDateTime
* Add a js_class to implement the Class trait without boilerplate
This also adds a JsInstance that verifies that `this` is of the proper
class, and an `Ignore` that ignore arguments.
The syntax is a bit special because of limitations of macro_rules. For
example, the way fields are defined. It was impossible to keep both
assignments (e.g. `public field = 123;`) and dynamic fields.
This reduces significantly the boilerplate for declaring classes. The
example in class.rs is more than twice as long (if you remove comments)
than the macro is.
* clippies
* Fix usage of macros
* Fix some imports issues
* Fix some imports issues, again
* Add a way to alias a function, e.g. change case
* Address comment and get rid of unwraps