0
Fork 0
mirror of https://github.com/logto-io/logto.git synced 2024-12-23 20:33:16 -05:00
logto/packages/connectors
renovate[bot] 6ecd92de0b
chore(deps): update dependency nock to v14.0.0-beta.7 (#5952)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-05-31 02:43:31 +00:00
..
connector-alipay-native
connector-alipay-web
connector-aliyun-dm
connector-aliyun-sms
connector-apple
connector-aws-ses
connector-azuread
connector-dingtalk-web feat(connector): add dingtalk connector (#5915) 2024-05-29 15:15:45 +08:00
connector-discord
connector-facebook
connector-feishu-web
connector-github chore(deps): update dependency nock to v14.0.0-beta.7 (#5952) 2024-05-31 02:43:31 +00:00
connector-google
connector-huggingface chore(deps): update dependency nock to v14.0.0-beta.7 (#5952) 2024-05-31 02:43:31 +00:00
connector-kakao
connector-logto-email
connector-logto-sms
connector-logto-social-demo
connector-mailgun
connector-mock-email
connector-mock-email-alternative
connector-mock-sms
connector-mock-social
connector-naver
connector-oauth2 chore(deps): update dependency nock to v14.0.0-beta.7 (#5952) 2024-05-31 02:43:31 +00:00
connector-oidc chore(deps): update dependency nock to v14.0.0-beta.7 (#5952) 2024-05-31 02:43:31 +00:00
connector-saml
connector-sendgrid-email
connector-smsaero
connector-smtp
connector-tencent-sms
connector-twilio-sms
connector-wechat-native
connector-wechat-web
connector-wecom
templates
.gitignore
README.md

Logto connectors directory

Template syncing

Since all connectors have a same pattern for package.json, here we leverage several techniques to avoid annoying copy-pastes:

When pnpm i

  • The "pnpm:devPreinstall" script in the project root executes templates/sync-preset.js that:
    • Check every connectors's package.json to see if there's any unexpected keys
    • Sync templates/package.json by REPLACING every template key (except dependency keys) in the current package.json with the value from the template package.json
    • Copies all config files to every connector directory
  • The hook in .pnpmfile.cjs of the project root merges dependency fields for every connector
    • Also we can update arbitrary fields in this hook, we still need to keep non-dependency fields in the connector's package.json since the hook only takes affect during pnpm i.

Caution Workspace dependencies should be defined in connector's package.json (not template) in order to let PNPM correctly resolves the workspace dependency tree;

Add a new custom field

Head to templates/sync-preset.js and update allowedCustomKeys.