-
-
Notifications
You must be signed in to change notification settings - Fork 20
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
TypeScript migration #309
TypeScript migration #309
Commits on Jul 31, 2023
-
other(ts): copy parser types from bookbrainz-utils
Since we also need them here, they will be deleted from there later.
Configuration menu - View commit details
-
Copy full SHA for 7679731 - Browse repository at this point
Copy the full SHA 7679731View commit details -
chore(deps): update @metabrainz/bookshelf to v1.4.0
This version includes type definitions.
Configuration menu - View commit details
-
Copy full SHA for 9381eee - Browse repository at this point
Copy the full SHA 9381eeeView commit details
Commits on Aug 3, 2023
-
refactor(types): introduce separate types for lazy-loaded properties
Also use consistent names for inserted and fetched models: * ModelT * ModelWithIdT * LazyLoadedModelT
Configuration menu - View commit details
-
Copy full SHA for 9812991 - Browse repository at this point
Copy the full SHA 9812991View commit details -
Configuration menu - View commit details
-
Copy full SHA for 242916d - Browse repository at this point
Copy the full SHA 242916dView commit details -
fix(types): make id and default flag of aliases optional
An alias only needs an id during updates if it is not a new one. As long as one item of an alias set is marked as default, the others do not need this attribute.
Configuration menu - View commit details
-
Copy full SHA for 2d42980 - Browse repository at this point
Copy the full SHA 2d42980View commit details
Commits on Aug 7, 2023
-
Configuration menu - View commit details
-
Copy full SHA for cc35dcb - Browse repository at this point
Copy the full SHA cc35dcbView commit details -
other(ts): export a type for the ORM
Currently all its properties except for `bookshelf` have an inferred type of `any`, but that's a start at least. The situation will improve as soon as the Bookshelf models have types.
Configuration menu - View commit details
-
Copy full SHA for 6b9235a - Browse repository at this point
Copy the full SHA 6b9235aView commit details -
Configuration menu - View commit details
-
Copy full SHA for 3134f41 - Browse repository at this point
Copy the full SHA 3134f41View commit details -
Configuration menu - View commit details
-
Copy full SHA for fdcf333 - Browse repository at this point
Copy the full SHA fdcf333View commit details -
Configuration menu - View commit details
-
Copy full SHA for a2307f5 - Browse repository at this point
Copy the full SHA a2307f5View commit details -
Configuration menu - View commit details
-
Copy full SHA for a93bc48 - Browse repository at this point
Copy the full SHA a93bc48View commit details -
other(ts): create a return type for
getEntitySetMetadataByType
Consequent usage of this type seems to also have revealed a bug...
Configuration menu - View commit details
-
Copy full SHA for df6ddcb - Browse repository at this point
Copy the full SHA df6ddcbView commit details
Commits on Sep 1, 2023
-
Configuration menu - View commit details
-
Copy full SHA for 53805a0 - Browse repository at this point
Copy the full SHA 53805a0View commit details -
Configuration menu - View commit details
-
Copy full SHA for 959cc8e - Browse repository at this point
Copy the full SHA 959cc8eView commit details -
Configuration menu - View commit details
-
Copy full SHA for 289a68e - Browse repository at this point
Copy the full SHA 289a68eView commit details -
other(ts): convert utils to TypeScript
Replace deprecated usage of `String.substr`.
Configuration menu - View commit details
-
Copy full SHA for aa539c2 - Browse repository at this point
Copy the full SHA aa539c2View commit details -
Configuration menu - View commit details
-
Copy full SHA for 2f861f8 - Browse repository at this point
Copy the full SHA 2f861f8View commit details -
Configuration menu - View commit details
-
Copy full SHA for 436984d - Browse repository at this point
Copy the full SHA 436984dView commit details -
Configuration menu - View commit details
-
Copy full SHA for a335e30 - Browse repository at this point
Copy the full SHA a335e30View commit details -
Configuration menu - View commit details
-
Copy full SHA for a553d13 - Browse repository at this point
Copy the full SHA a553d13View commit details -
other(ts): add minimal type definitions to all bookshelf models
- Batch-rename all JS modules: `rename .js .ts src/models/{*,*/*}.js` - Import and add Bookshelf type to each model using global search and replace - Adapt helper function in edition.ts - Update test to refer to the generated JS files in the lib/ directory Tests are passing but the bookshelf models still cause type errors caused by their non-standard inheritance.
Configuration menu - View commit details
-
Copy full SHA for e3c529f - Browse repository at this point
Copy the full SHA e3c529fView commit details -
Configuration menu - View commit details
-
Copy full SHA for 0335676 - Browse repository at this point
Copy the full SHA 0335676View commit details -
refactor(models): replace
Model.forge()
withnew Model()
https://bookshelfjs.org/api.html#Model-static-forge > A simple helper function to instantiate a new Model without needing new. Using the constructor syntax avoids a few type errors with chained calls.
Configuration menu - View commit details
-
Copy full SHA for b699ab0 - Browse repository at this point
Copy the full SHA b699ab0View commit details
Commits on Sep 12, 2023
-
chore: use consistent type import syntax
Co-authored-by: Monkey Do <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for ee7e062 - Browse repository at this point
Copy the full SHA ee7e062View commit details -
Configuration menu - View commit details
-
Copy full SHA for f9b5d4f - Browse repository at this point
Copy the full SHA f9b5d4fView commit details -
refactor(util): make date number parsing better readable
Co-authored-by: Monkey Do <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 5a519ec - Browse repository at this point
Copy the full SHA 5a519ecView commit details -
fix(ts): call instance method instead of class method
Co-authored-by: Monkey Do <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 10f9b55 - Browse repository at this point
Copy the full SHA 10f9b55View commit details -
Configuration menu - View commit details
-
Copy full SHA for 7843a11 - Browse repository at this point
Copy the full SHA 7843a11View commit details
Commits on Sep 21, 2023
-
Configuration menu - View commit details
-
Copy full SHA for dfc71e4 - Browse repository at this point
Copy the full SHA dfc71e4View commit details
Commits on Oct 16, 2023
-
fix(import): avoid conflicting usage of entityType by using QueuedEntity
Type was copied from bookbrainz-utils, where it has been removed.
Configuration menu - View commit details
-
Copy full SHA for 1e155ab - Browse repository at this point
Copy the full SHA 1e155abView commit details -
Configuration menu - View commit details
-
Copy full SHA for cdf0dcc - Browse repository at this point
Copy the full SHA cdf0dccView commit details -
fix(import): properly extract id from knex query result
Finally the first test import of a random OpenLibrary author succeeded!
Configuration menu - View commit details
-
Copy full SHA for d0c9658 - Browse repository at this point
Copy the full SHA d0c9658View commit details