Skip to content
This repository has been archived by the owner on May 29, 2024. It is now read-only.

Readme create connection loader class #10

Open
Amorim33 opened this issue Dec 3, 2023 · 1 comment
Open

Readme create connection loader class #10

Amorim33 opened this issue Dec 3, 2023 · 1 comment

Comments

@Amorim33
Copy link

Amorim33 commented Dec 3, 2023

Is this part of the documentation correct?

image

UserConnectionLoader is not been used.

Ref.
https://github.com/danielrearden/slonik-dataloaders#createconnectionloaderclass

@Amorim33
Copy link
Author

Amorim33 commented Dec 3, 2023

Also, missing a comma here:

image

Fix

const UserByIdLoader = createNodeByIdLoaderClass({
  column: {
    name: 'unique_id',
    type: 'text',
  },
  query: sql.type(User)`
    SELECT
      *
    FROM user
  `,
});

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant