Skip to content

Commit 37a1186

Browse files
committed
More explicit on new packages
1 parent 8a6fde7 commit 37a1186

File tree

5 files changed

+7
-6
lines changed

5 files changed

+7
-6
lines changed

AGENTS.md

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,21 +7,18 @@
77
- When adding dependencies, use `npm install`
88
- Do not add it to workspace root
99
- If it is an existing package, must use consistent version: either use existing version for the package or consider bumping every dependents to latest
10-
- Production code must avoid packages from Node.js packages or polyfills
10+
- Unless stated otherwise, avoid Node.js packages or polyfills
1111
- Use `ReadableStream`, `WritableStream`, `TransformStream`, instead of Node.js `buffer`
1212
- Use Web Cryptography instead of Node.js `crypto`
1313
- Do not use `fs`-like or `net`-like packages
1414
- Do not use any Browserify-like packages
15-
- When adding pacakges to the following packages, verify:
16-
- `/packages/api/` and `/packages/core/`: Newly added packages and transient packages must be platform-neutral
17-
- `/packages/test/`: Open to any packages
18-
- `/packages/*/`: Newly added packages and transient packages must be either platform-neutral or targetting browser
15+
- Unless stated otherwise, verify newly added packages and transient packages must be either platform-neutral, browser-specific, or React-specific
1916
- Do not add external/publishing packages unless explicitly requested
2017
- Always prefix internal/non-publishing packages with `@msinternal/` to prevent package squatting
2118

2219
### General
2320

24-
- Unless stated otherwise, assume browser and React is available, avoid Node.js
21+
- Unless stated otherwise, avoid Node.js
2522
- Apply our latest coding style to every file changed
2623
- Avoid spaghetti code: on new feature with a similar existing feature, refactor existing one before writing new feature
2724
- This does not applies to test code

packages/api/AGENTS.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,4 @@
33
## Coding
44

55
- Allow browser technologies, but no Node.js nor React
6+
- Newly added packages and transient packages must be platform-neutral or browser-specific

packages/base/AGENTS.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,4 @@
33
## Coding
44

55
- Stay platform neutral, no browser technologies, no Node.js, no React
6+
- Newly added packages and transient packages must be platform-neutral

packages/core/AGENTS.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,4 @@
33
## Coding
44

55
- Stay platform neutral, no browser technologies, no Node.js, no React
6+
- Newly added packages and transient packages must be platform-neutral

packages/test/AGENTS.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,4 @@
33
## Coding
44

55
- All technologies are allowed, including Node.js
6+
- Browser-specific, React-specific, Node.js packages are allowed

0 commit comments

Comments
 (0)