Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
63f5114
feat: scaffold TypeScript project with tsup, vitest, and modern config
joalves Mar 28, 2026
f881641
feat: add shared type definitions and custom error classes
joalves Mar 28, 2026
ce6bb53
feat: add murmur3_32 hash implementation
joalves Mar 28, 2026
8f6a7af
feat: add MD5 hash implementation
joalves Mar 28, 2026
4023820
feat: add hashing utilities (stringToUint8Array, base64UrlNoPadding, …
joalves Mar 28, 2026
6651b79
feat: add core utilities (isObject, isEqualsDeep, chooseVariant, inse…
joalves Mar 28, 2026
0307d11
feat: add VariantAssigner with murmur3-based probability
joalves Mar 28, 2026
d47db22
feat: add JsonExpr evaluator with type conversion and comparison
joalves Mar 28, 2026
879b261
feat: add all 20 JsonExpr operators
joalves Mar 28, 2026
df6b082
feat: add JsonExpr facade and AudienceMatcher
joalves Mar 28, 2026
dc6d8e4
feat: add HTTP client with retry logic and exponential backoff
joalves Mar 28, 2026
4ac61c7
feat: add ContextDataProvider and ContextPublisher
joalves Mar 28, 2026
a484d1d
feat: add Context class with experiment assignment and lifecycle mana…
joalves Mar 28, 2026
a84bd00
feat: add SDK class with context creation and configuration
joalves Mar 29, 2026
fba6cf1
feat: add mergeConfig utility for experiment variable injection
joalves Mar 29, 2026
9977b5a
fix: resolve TypeScript strict mode errors in context and client
joalves Mar 29, 2026
a765750
feat: add public API exports
joalves Mar 29, 2026
d6f1bd5
chore: remove old source files and add implementation plan
joalves Mar 29, 2026
9acb1f7
feat: add optional legacy support with injectable polyfills and ES201…
joalves Mar 30, 2026
7591421
fix: forward fetchImpl/AbortControllerImpl through SDK, correct READM…
joalves Mar 31, 2026
1387ff4
feat: merge best of both TS rewrites — interface-based DI, bug fixes,…
joalves Apr 10, 2026
f6770b1
docs: update README for v2 API — DI interfaces, error types, readyErr…
joalves Apr 18, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .browserslistrc

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# Session Context: TypeScript Rewrite Plan

## Session ID
a9973aa3-2e87-420a-9c57-c48fd5f3a2d4

## Goal
Create a comprehensive implementation plan to rewrite the ABSmartly JavaScript SDK in TypeScript from scratch.

## What Was Done
1. Created git worktree `worktree-typescript-rewrite` based on `main`
2. Thoroughly explored the entire codebase (43 source files, 34 test files, all config)
3. Read every source file, understanding all types, APIs, and algorithms
4. Read all 20 JsonExpr operators
5. Read all 14 test files to understand test patterns and fixture data
6. Wrote comprehensive 17-task implementation plan

## Plan Location
`docs/superpowers/plans/2026-03-28-typescript-rewrite.md`

## Key Decisions
- **Drop legacy support**: Node 18+ / modern browsers only (was Node 6+ / IE 10+)
- **Drop dependencies**: node-fetch, rfdc, core-js (use native fetch, structuredClone)
- **Drop polyfills**: fetch-shim, abort-controller-shim, platform detection wrappers
- **Drop Babel**: Use tsup (esbuild-based) for bundling ESM + CJS + browser IIFE
- **Test framework**: Vitest instead of Jest
- **Keep identical**: Public API, hashing algorithms, variant assignment, client retry logic

## Task Breakdown (17 tasks)
1. Project scaffolding & build system (package.json, tsconfig, tsup, vitest)
2. Types & errors
3. Murmur3 hash
4. MD5 hash
5. Hashing utilities
6. Core utilities (isObject, isEqualsDeep, etc.)
7. Variant assigner
8. JsonExpr evaluator
9. JsonExpr operators (all 20 in one file)
10. JsonExpr facade & AudienceMatcher
11. HTTP client with retry
12. Provider & publisher
13. Context class (largest module)
14. SDK class
15. Config merge utility
16. Public API & index exports
17. Full integration & cleanup
10 changes: 0 additions & 10 deletions .editorconfig

This file was deleted.

2 changes: 0 additions & 2 deletions .eslintignore

This file was deleted.

58 changes: 0 additions & 58 deletions .eslintrc.js

This file was deleted.

5 changes: 0 additions & 5 deletions .prettierignore

This file was deleted.

7 changes: 0 additions & 7 deletions .prettierrc.json

This file was deleted.

Loading