Skip to content

Commit

Permalink
Merge pull request #24439 from Expensify/hayata-edit-style-guideline
Browse files Browse the repository at this point in the history
Edit TS Style Guide to ban new TS code
  • Loading branch information
amyevans authored Aug 11, 2023
2 parents a2096c8 + 952e7c4 commit f0a6977
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions contributingGuides/TS_STYLE.md
Original file line number Diff line number Diff line change
Expand Up @@ -487,6 +487,8 @@ declare module "external-library-name" {
> This section contains instructions that are applicable during the migration.
- 🚨 DO NOT write new code in TypeScript yet. The only time you write TypeScript code is when the file you're editing has already been migrated to TypeScript by the migration team. This guideline will be updated once it's time for new code to be written in TypeScript. If you're doing a major overhaul or refactoring of particular features or utilities of App and you believe it might be beneficial to migrate relevant code to TypeScript as part of the refactoring, please ask in the #expensify-open-source channel about it (and prefix your message with `TS ATTENTION:`).
- If you're migrating a module that doesn't have a default implementation (i.e. `index.ts`, e.g. `getPlatform`), convert `index.website.js` to `index.ts`. Without `index.ts`, TypeScript cannot get type information where the module is imported.
- Deprecate the usage of `underscore`. Use vanilla methods from JS instead. Only use `lodash` when there is no easy vanilla alternative (eg. `lodashMerge`). eslint: [`no-restricted-imports`](https://eslint.org/docs/latest/rules/no-restricted-imports)
Expand Down

0 comments on commit f0a6977

Please sign in to comment.