| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
chore: updated issue template (#2230) Those lines can create messy markdown when not spaced out properly. E.g., following screenshot: | 2 年前 | |
chore(yarn): migrate to Yarn 4 + native workspaces (#3594) ## 🎯 Goal Move us onto Yarn 4 with native workspaces and drop Lerna. The `.yarnrc.yml` was already half-migrated, but `yarnPath` still pointed at the v1 binary — this finishes that off. ## 🛠 Implementation details Tooling only; nothing in `package/src` changes. Roughly: - `.yarn/releases/` swapped to 4.14.1, and all seven `yarn.lock` files migrated v1 → v8 in place — resolutions preserved, no drift. - Single root `workspaces` array now covers `package/`, both native wrapper packages, and all three example apps. `link:../../package/*` becomes `workspace:^`, nested lockfiles are gone, and the install-and-build-sdk composite action collapses to one `yarn install --immutable`. - Shared-native sync + husky setup run from the core SDK workspace's `postinstall` (Yarn 4 doesn't run root-workspace lifecycle scripts on install). - Lerna removed: `release/release.config.js` no longer reads `lerna.json`, and `release` / `release-next` / `extract-changelog` use `yarn workspaces foreach`. - Husky 6 → 9 (the v6 hook boilerplate is on the deprecation path). - `.yarnrc.yml` picks up the conservative hardening tier: `enableHardenedMode`, `npmMinimalAgeGate: 3d`, `enableScripts: false` with a small `dependenciesMeta` allowlist for the packages that genuinely need to build (`@swc/core`, `better-sqlite3`, `react-native-nitro-modules`, `unrs-resolver`). - CI workflows cache `.yarn/` via setup-node; drive-by fix for the deprecated `::set-output` calls in `changelog-preview.yml`. ## 🎨 UI Changes N/A. ## 🧪 Testing Locally: `yarn install --immutable` is clean, `yarn lint` + `yarn build` pass, husky hooks fired on every commit in this PR. Can't verify locally: example apps on real devices, and the release flow itself. The Lerna → `yarn workspaces foreach` rewrite is the riskiest single change — worth a dry-run on a throwaway branch before merging. ## ☑️ Checklist - [x] I have signed the [Stream CLA](https://docs.google.com/forms/d/e/1FAIpQLScFKsKkAJI7mhCr7K9rEIOpqIDThrWxuvxnwUq2XkHyG154vQ/viewform) (required) - [x] PR targets the `develop` branch - [x] Documentation is updated - [ ] New code is tested in main example apps, including all possible scenarios - [ ] SampleApp iOS and Android - [ ] Expo iOS and Android --------- Co-authored-by: Ivan Sekovanikj <ivan.sekovanikj@getstream.io> | 3 个月前 | |
chore: upgrade to TypeScript 6.0.3, ES2022 target, and shared ts-config presets (#3663) ## What & why Upgrades every workspace to **TypeScript 6.0.3** with **`target: ES2022`**, and removes tsconfig duplication via a new shared preset package. Enabling type-checking across the previously-unchecked packages also surfaced (and this PR fixes) a pre-existing bug in the core package's published type resolution plus a batch of latent type errors. ## Changes ### Shared config - New **private** `@stream-io/typescript-config` workspace (`configs/typescript-config/`): - `base.json` — cross-cutting policy (ES2022 target, strict, interop, …) - `library.json` — full React Native library config (extends `base`) - Core, the native/expo wrappers, and all 3 example apps extend these instead of duplicating compiler options. Example apps array-extend `["<framework base>", "@stream-io/typescript-config/base.json"]`. ### TypeScript 6.0.3 / ES2022 - TS `6.0.3` in all 7 manifests; `target: ES2022` everywhere. - `lib` kept at `ESNext` — the SDK uses the ES2023 `Array.prototype.toReversed()`. - TS 6.0 no longer auto-includes `@types/jest`, so it's referenced explicitly from a test-only `package/src/__tests__/jest-globals.d.ts` (excluded from the published build). ### Core publishing fix (consumer-facing) - `react-native-builder-bob` emitted declarations under `lib/typescript/src/` while `package.json#types` pointed at `lib/typescript/index.d.ts` — so TS consumers couldn't resolve the SDK's types via `types`. Added `rootDir: "./src"` so declarations emit flat to match `types`. This was also the root cause that blocked the wrappers/examples from resolving core's types. - Exported `PickImageOptions` from the core entrypoint (defined+exported in `native.ts` but never surfaced from `index`). ### Wrappers (`stream-chat-react-native`, `stream-chat-expo`) - Added a `typecheck` script + tsconfig (they had neither). The dynamic optional-`require` shims relax `noImplicitAny`/`strictNullChecks`/unused checks (kept `noImplicitReturns`). - Fixed real bugs: missing `return`s in `shareImage`, missing `resizeMode`/`rate` on the video shim, an inconsistent `startRecording` return shape. ### Example apps - Fixed ~60 pre-existing latent type errors unmasked by enabling typecheck: theme palette typing (the legacy flat `colors` palette, read via a local `AppTheme` cast — behavior-preserving), null-safety guards, and several SDK-API-drift fixes. ### CI - `check-pr.yml` now runs `yarn typecheck` across the whole workspace (core + 2 wrappers + 3 examples) instead of only the core package; the root `typecheck` aggregate includes the wrappers. ## Verification - `yarn build` ✅ - `yarn typecheck` (core + 2 wrappers + 3 examples) ✅ **0 errors** - `yarn lint` ✅ ## Notes for reviewers - **Commit type**: filed as `chore:` (release-neutral). The core changes (flat `types` path + `PickImageOptions` export) are genuinely consumer-facing — if you want them shipped, retype as `fix:` to cut a patch. - **Wrapper strictness**: `strictNullChecks`/`noImplicitAny` are relaxed **only** for the two wrapper packages (dynamic optional-dep shims), not for core. - **Example theming**: the apps' custom `colors` palette was already inert for SDK theming (the SDK reads semantics/primitives, not `theme.colors`); this PR preserves that behavior. Migrating the palette to the token model to restore custom branding would be a separate enhancement. - Did not run the full unit suite locally (the only core source change is the additive `PickImageOptions` export); CI runs `test:coverage`. --------- Co-authored-by: Ivan Sekovanikj <ivan.sekovanikj@getstream.io> | 1 个月前 |
| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
| 2 年前 | ||
| 3 个月前 | ||
| 1 个月前 |