Socket
Socket
Sign inDemoInstall

remult

Package Overview
Dependencies
Maintainers
2
Versions
588
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

remult - npm Package Versions

1
59

0.27.5

Diff

Changelog

Source

[0.27.5] 2024-08-23

  • #474 When using knex, an id column with auto-increment that is not named id in the db gave an error
noamhonig
published 0.22.13-exp.0 •

noamhonig
published 0.27.5-next.0 •

noamhonig
published 0.27.4 •

noamhonig
published 0.27.3 •

Changelog

Source

[0.27.3] 2024-08-14

  • Changed RelationOptions to be an extendable interface and not a type
noamhonig
published 0.27.2 •

Changelog

Source

[0.27.2] TBD

  • Added request to remult.context that'll be available through the request lifecycle - to access it please extend the RemultContext type as follows
    import type express from 'express'
    declare module 'remult' {
      export interface RemultContext {
        request?: express.Request
      }
    }
    
noamhonig
published 0.27.2-next.0 •

noamhonig
published 0.27.1 •

Changelog

Source

[0.27.13] TBD

  • fixed an error where from json returned a row that didn't have an id and could cause problems
noamhonig
published 0.27.1-next.0 •

noamhonig
published 0.27.0 •

Changelog

Source

[0.27.0] TBD

API BREAKING CHANGE - Improved Typescript typing

Typescript version 5.4 included many changes that cause unknown & any to behave differently breaking existing code for some project.

In this version we reviewed the external api and made sure that it matches TS 5.4 while still supporting older version of TS (4.6)

Theses change are likely to cause build errors in existing projects, but in most cases these errors represent potential bugs that should be addressed. Here's the list of significant changes:

  • findFirst, findOne and findId can return undefined when the row is not found, if you're sure that the row exists, add a ! after it, for example:
    let p = await repo(Person).findId(7) // p will be Person | undefined in the new version
    let q = (await repo(Person).findId(7))! // p will be Person
    
  • Decorators that use entity, now require to define the entity in the generic definition. Previously you could have the following code:
    @Fields.string({
      validate: task => task.title.length > 2
    })
    title=''
    
    Now, that code will return an error that title is not a member of unknown. To fix that add the Entity generic definition:
    @Fields.string<Task>({
      validate: task => task.title.length > 2
      title = ''
    })
    
  • FieldMetadata.key was changed from string to keyof entityType making it easier to traverse the object.
  • error in EntityRef, FieldRef and ControllerRef can be undefined when there is no error
  • Change = any to = unknown in most generic definitions
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc