mirror of
https://github.com/bitwarden/browser
synced 2026-02-06 11:43:51 +00:00
Write plan
This commit is contained in:
269
.kiro/specs/ts-strict-migration/design.md
Normal file
269
.kiro/specs/ts-strict-migration/design.md
Normal file
@@ -0,0 +1,269 @@
|
||||
# Design Document
|
||||
|
||||
## Overview
|
||||
|
||||
The TypeScript strict mode migration will systematically enable strict compilation across the entire Bitwarden client codebase. The project currently uses `typescript-strict-plugin` which allows gradual migration by using `@ts-strict-ignore` comments to exclude files from strict checking. The migration involves removing these ignore comments from files after fixing strict mode violations, and finally removing the plugin and enabling native TypeScript strict mode.
|
||||
|
||||
The codebase is currently configured with `"strict": false` in the base TypeScript configuration, with the `typescript-strict-plugin` providing selective strict checking. Files with `@ts-strict-ignore` comments are excluded from strict mode checking, allowing for incremental migration.
|
||||
|
||||
## Architecture
|
||||
|
||||
### Migration Strategy
|
||||
|
||||
The migration follows a bottom-up approach, starting with core libraries that have minimal dependencies and working up to applications that depend on multiple libraries. This ensures that strict mode violations are fixed at the foundation level first.
|
||||
|
||||
**Migration Order:**
|
||||
|
||||
1. Core infrastructure libraries (`platform`, `common`)
|
||||
2. Domain-specific libraries (`auth`, `vault`, `key-management`, etc.)
|
||||
3. UI libraries (`components`, `angular`)
|
||||
4. Applications (`cli`, `browser`, `desktop`, `web`)
|
||||
5. Licensed features (`bitwarden_license`)
|
||||
|
||||
### TypeScript Configuration Changes
|
||||
|
||||
The migration will update TypeScript configurations to enable strict mode:
|
||||
|
||||
```json
|
||||
{
|
||||
"compilerOptions": {
|
||||
"strict": true,
|
||||
// Individual strict flags (enabled by strict: true)
|
||||
"noImplicitAny": true,
|
||||
"strictNullChecks": true,
|
||||
"strictFunctionTypes": true,
|
||||
"strictBindCallApply": true,
|
||||
"strictPropertyInitialization": true,
|
||||
"noImplicitReturns": true,
|
||||
"noImplicitThis": true
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
### Incremental Migration Approach
|
||||
|
||||
The migration uses a phased approach where each library/application is migrated individually:
|
||||
|
||||
1. **Assessment Phase**: Run TypeScript compiler with strict mode to identify violations
|
||||
2. **Fix Phase**: Systematically fix strict mode violations
|
||||
3. **Validation Phase**: Ensure tests pass and functionality is preserved
|
||||
4. **Configuration Phase**: Update tsconfig.json to enable strict mode for that module
|
||||
|
||||
## Components and Interfaces
|
||||
|
||||
### TypeScript Configuration Management
|
||||
|
||||
**Base Configuration (`tsconfig.base.json`)**
|
||||
|
||||
- Central configuration that all projects extend
|
||||
- Will be updated to enable strict mode once all modules are migrated
|
||||
- Maintains path mappings and compiler options
|
||||
|
||||
**Project-Specific Configurations**
|
||||
|
||||
- Each app and library has its own tsconfig.json that extends the base
|
||||
- Individual projects can temporarily override strict settings during migration
|
||||
- Angular-specific configurations maintain `strictTemplates: true`
|
||||
|
||||
### Migration Tooling
|
||||
|
||||
**TypeScript Strict Plugin**
|
||||
|
||||
- Currently installed and configured (`typescript-strict-plugin@2.4.4`)
|
||||
- Provides gradual strict mode checking
|
||||
- Will be removed once native strict mode is fully enabled
|
||||
|
||||
**Type Checking Scripts**
|
||||
|
||||
- `scripts/test-types.js` runs type checking across all libraries
|
||||
- Will be updated to use native strict mode checking
|
||||
- Provides concurrent type checking for faster feedback
|
||||
|
||||
### Common Strict Mode Patterns
|
||||
|
||||
**Null Safety Patterns**
|
||||
|
||||
```typescript
|
||||
// Before: Potential null/undefined access
|
||||
function processUser(user: User) {
|
||||
return user.name.toUpperCase(); // Error if user.name is null/undefined
|
||||
}
|
||||
|
||||
// After: Explicit null checking
|
||||
function processUser(user: User) {
|
||||
return user.name?.toUpperCase() ?? "Unknown";
|
||||
}
|
||||
```
|
||||
|
||||
**Property Initialization**
|
||||
|
||||
```typescript
|
||||
// Before: Uninitialized properties
|
||||
class UserService {
|
||||
private apiClient: ApiClient; // Error: not initialized
|
||||
}
|
||||
|
||||
// After: Explicit initialization
|
||||
class UserService {
|
||||
private apiClient!: ApiClient; // Definite assignment assertion
|
||||
// OR
|
||||
private apiClient: ApiClient | undefined;
|
||||
// OR
|
||||
private apiClient = new ApiClient();
|
||||
}
|
||||
```
|
||||
|
||||
**Function Type Safety**
|
||||
|
||||
```typescript
|
||||
// Before: Implicit any parameters
|
||||
function handleCallback(callback) {
|
||||
// Error: implicit any
|
||||
callback();
|
||||
}
|
||||
|
||||
// After: Explicit typing
|
||||
function handleCallback(callback: () => void) {
|
||||
callback();
|
||||
}
|
||||
```
|
||||
|
||||
## Data Models
|
||||
|
||||
### Migration Tracking
|
||||
|
||||
**Violation Categories**
|
||||
|
||||
- Null/undefined safety violations
|
||||
- Implicit any type violations
|
||||
- Uninitialized property violations
|
||||
- Function type violations
|
||||
- Implicit return violations
|
||||
- Implicit this context violations
|
||||
|
||||
**Progress Tracking**
|
||||
|
||||
- Track completion status per library/application
|
||||
- Document common patterns and solutions
|
||||
- Maintain list of complex cases requiring special handling
|
||||
|
||||
## Error Handling
|
||||
|
||||
### Migration Error Categories
|
||||
|
||||
**Type Assertion Errors**
|
||||
|
||||
- Use type guards instead of type assertions where possible
|
||||
- Document cases where assertions are necessary
|
||||
- Prefer narrowing types over assertions
|
||||
|
||||
**Legacy Code Compatibility**
|
||||
|
||||
- Some legacy patterns may require gradual migration
|
||||
- Use `// @ts-ignore` sparingly and document reasons
|
||||
- Plan for future refactoring of problematic patterns
|
||||
|
||||
**Third-Party Library Issues**
|
||||
|
||||
- Some external libraries may not have strict-compatible types
|
||||
- Use module augmentation or custom type definitions
|
||||
- Document workarounds for library-specific issues
|
||||
|
||||
### Rollback Strategy
|
||||
|
||||
**Per-Module Rollback**
|
||||
|
||||
- Each module can independently disable strict mode if critical issues arise
|
||||
- Maintain ability to revert individual modules without affecting others
|
||||
- Document rollback procedures and criteria
|
||||
|
||||
## Testing Strategy
|
||||
|
||||
### Automated Testing
|
||||
|
||||
**Type Checking Integration**
|
||||
|
||||
- Integrate strict mode checking into CI/CD pipeline
|
||||
- Ensure all type checking passes before merging
|
||||
- Update existing type checking scripts to use strict mode
|
||||
|
||||
**Unit Test Compatibility**
|
||||
|
||||
- Ensure all existing unit tests continue to pass
|
||||
- Fix test-specific strict mode violations
|
||||
- Maintain test coverage during migration
|
||||
|
||||
**Integration Testing**
|
||||
|
||||
- Run full application builds to ensure no runtime regressions
|
||||
- Test critical user flows after each module migration
|
||||
- Validate that all applications start and function correctly
|
||||
|
||||
### Manual Testing
|
||||
|
||||
**Application Functionality**
|
||||
|
||||
- Test core features in each application after migration
|
||||
- Verify that user workflows remain intact
|
||||
- Check for any runtime errors introduced by strict mode fixes
|
||||
|
||||
**Performance Validation**
|
||||
|
||||
- Ensure strict mode changes don't impact application performance
|
||||
- Monitor build times and compilation speed
|
||||
- Validate that bundle sizes remain reasonable
|
||||
|
||||
### Continuous Validation
|
||||
|
||||
**Pre-commit Hooks**
|
||||
|
||||
- Update existing hooks to enforce strict mode compliance
|
||||
- Prevent new strict mode violations from being introduced
|
||||
- Maintain code quality standards throughout migration
|
||||
|
||||
**Development Workflow**
|
||||
|
||||
- Update development scripts to use strict mode
|
||||
- Provide clear error messages for strict mode violations
|
||||
- Integrate strict checking into IDE configurations
|
||||
|
||||
## Implementation Phases
|
||||
|
||||
### Phase 1: Infrastructure Setup
|
||||
|
||||
- Update tooling and scripts for strict mode checking
|
||||
- Establish migration patterns and documentation
|
||||
- Set up tracking and validation processes
|
||||
|
||||
### Phase 2: Core Libraries Migration
|
||||
|
||||
- Migrate `libs/platform` and `libs/common`
|
||||
- Establish patterns for common strict mode fixes
|
||||
- Validate that dependent libraries still compile
|
||||
|
||||
### Phase 3: Domain Libraries Migration
|
||||
|
||||
- Migrate domain-specific libraries in dependency order
|
||||
- Apply established patterns from core library migration
|
||||
- Maintain compatibility with unmigrated modules
|
||||
|
||||
### Phase 4: UI and Application Migration
|
||||
|
||||
- Migrate UI libraries and components
|
||||
- Migrate applications (CLI, browser, desktop, web)
|
||||
- Ensure full application functionality
|
||||
|
||||
### Phase 5: Final Configuration
|
||||
|
||||
- Enable strict mode in base TypeScript configuration
|
||||
- Remove typescript-strict-plugin dependency
|
||||
- Update documentation and development guidelines
|
||||
|
||||
## Success Criteria
|
||||
|
||||
- All TypeScript compilation passes with strict mode enabled
|
||||
- All existing tests continue to pass
|
||||
- All applications build and run successfully
|
||||
- No runtime regressions introduced
|
||||
- Development workflow improved with better type safety
|
||||
- Clear documentation of migration patterns and best practices
|
||||
76
.kiro/specs/ts-strict-migration/requirements.md
Normal file
76
.kiro/specs/ts-strict-migration/requirements.md
Normal file
@@ -0,0 +1,76 @@
|
||||
# Requirements Document
|
||||
|
||||
## Introduction
|
||||
|
||||
This feature involves migrating the entire Bitwarden client codebase to use TypeScript strict mode. TypeScript strict mode enables a comprehensive set of type checking behaviors that catch common programming errors at compile time, improving code quality, maintainability, and developer experience. The migration will systematically enable strict mode across all applications (browser, web, desktop, CLI) and shared libraries while maintaining functionality and ensuring no regressions.
|
||||
|
||||
## Requirements
|
||||
|
||||
### Requirement 1
|
||||
|
||||
**User Story:** As a developer working on the Bitwarden codebase, I want TypeScript strict mode enabled so that I can catch type-related bugs at compile time and have better code safety guarantees.
|
||||
|
||||
#### Acceptance Criteria
|
||||
|
||||
1. WHEN TypeScript compilation runs THEN the compiler SHALL enforce strict null checks across all source files
|
||||
2. WHEN TypeScript compilation runs THEN the compiler SHALL enforce strict function types checking
|
||||
3. WHEN TypeScript compilation runs THEN the compiler SHALL enforce strict bind/call/apply checks
|
||||
4. WHEN TypeScript compilation runs THEN the compiler SHALL enforce strict property initialization checks
|
||||
5. WHEN TypeScript compilation runs THEN the compiler SHALL enforce no implicit any types
|
||||
6. WHEN TypeScript compilation runs THEN the compiler SHALL enforce no implicit returns
|
||||
7. WHEN TypeScript compilation runs THEN the compiler SHALL enforce no implicit this context
|
||||
|
||||
### Requirement 2
|
||||
|
||||
**User Story:** As a developer, I want all existing TypeScript configuration files updated to enable strict mode so that the entire codebase benefits from enhanced type safety.
|
||||
|
||||
#### Acceptance Criteria
|
||||
|
||||
1. WHEN reviewing tsconfig.json files THEN all configuration files SHALL have "strict": true enabled
|
||||
2. WHEN reviewing tsconfig.json files THEN all strict-related flags SHALL be consistently configured
|
||||
3. WHEN building any application or library THEN the build process SHALL use strict TypeScript compilation
|
||||
4. WHEN running tests THEN the test compilation SHALL also use strict mode
|
||||
|
||||
### Requirement 3
|
||||
|
||||
**User Story:** As a developer, I want all existing code to be compatible with strict mode so that the migration doesn't break existing functionality.
|
||||
|
||||
#### Acceptance Criteria
|
||||
|
||||
1. WHEN enabling strict mode THEN all existing TypeScript files SHALL compile without strict mode errors
|
||||
2. WHEN fixing strict mode violations THEN the fixes SHALL maintain existing functionality
|
||||
3. WHEN fixing strict mode violations THEN the fixes SHALL not introduce runtime regressions
|
||||
4. WHEN fixing strict mode violations THEN the fixes SHALL follow TypeScript best practices
|
||||
|
||||
### Requirement 4
|
||||
|
||||
**User Story:** As a developer, I want a systematic approach to fixing strict mode violations so that the migration is manageable and trackable.
|
||||
|
||||
#### Acceptance Criteria
|
||||
|
||||
1. WHEN migrating code THEN strict mode violations SHALL be fixed incrementally by library/application
|
||||
2. WHEN migrating code THEN each fix SHALL be isolated and testable
|
||||
3. WHEN migrating code THEN priority SHALL be given to core libraries before applications
|
||||
4. WHEN migrating code THEN the migration SHALL start with libraries that have fewer dependencies
|
||||
|
||||
### Requirement 5
|
||||
|
||||
**User Story:** As a developer, I want comprehensive testing during the migration so that I can be confident no functionality is broken.
|
||||
|
||||
#### Acceptance Criteria
|
||||
|
||||
1. WHEN fixing strict mode violations THEN existing unit tests SHALL continue to pass
|
||||
2. WHEN fixing strict mode violations THEN integration tests SHALL continue to pass
|
||||
3. WHEN fixing strict mode violations THEN the build process SHALL complete successfully for all applications
|
||||
4. WHEN fixing strict mode violations THEN type checking SHALL pass without errors or warnings
|
||||
|
||||
### Requirement 6
|
||||
|
||||
**User Story:** As a developer, I want clear documentation of the migration process so that I understand what changes were made and why.
|
||||
|
||||
#### Acceptance Criteria
|
||||
|
||||
1. WHEN the migration is complete THEN there SHALL be documentation of common strict mode patterns used
|
||||
2. WHEN the migration is complete THEN there SHALL be guidelines for maintaining strict mode compliance
|
||||
3. WHEN the migration is complete THEN there SHALL be examples of how strict mode violations were resolved
|
||||
4. WHEN encountering complex strict mode issues THEN there SHALL be documented solutions and rationale
|
||||
212
.kiro/specs/ts-strict-migration/tasks.md
Normal file
212
.kiro/specs/ts-strict-migration/tasks.md
Normal file
@@ -0,0 +1,212 @@
|
||||
# Implementation Plan
|
||||
|
||||
- [-] 1. Set up infrastructure and tooling for strict mode migration
|
||||
|
||||
- Create utility scripts to identify files with @ts-strict-ignore comments
|
||||
- Implement automated testing for strict mode compliance
|
||||
|
||||
- [ ] 2. Migrate core platform libraries
|
||||
- [ ] 2.1 Migrate libs/platform to strict mode
|
||||
|
||||
- Remove @ts-strict-ignore comments from platform library files
|
||||
- Fix null/undefined safety violations in platform abstractions
|
||||
- Fix implicit any type violations in platform services
|
||||
- Fix uninitialized property violations in platform classes
|
||||
- Update platform library tsconfig.json to enable strict mode
|
||||
- Run tests to ensure no regressions in platform functionality
|
||||
- _Requirements: 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 3.1, 3.2, 3.3_
|
||||
|
||||
- [ ] 2.2 Migrate libs/common to strict mode
|
||||
|
||||
- Remove @ts-strict-ignore comments from common library files
|
||||
- Fix strict null checks violations in core business logic
|
||||
- Fix strict function types violations in common utilities
|
||||
- Fix strict property initialization violations in common models
|
||||
- Update common library tsconfig.json to enable strict mode
|
||||
- Run comprehensive tests to validate core functionality
|
||||
- _Requirements: 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 3.1, 3.2, 3.3_
|
||||
|
||||
- [ ] 3. Migrate domain-specific libraries
|
||||
- [ ] 3.1 Migrate libs/auth to strict mode
|
||||
|
||||
- Remove @ts-strict-ignore comments from auth library files
|
||||
- Fix strict mode violations in authentication services
|
||||
- Fix strict mode violations in identity management code
|
||||
- Update auth library tsconfig.json to enable strict mode
|
||||
- Run auth-specific tests to ensure login/logout functionality works
|
||||
- _Requirements: 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 3.1, 3.2, 3.3_
|
||||
|
||||
- [ ] 3.2 Migrate libs/vault to strict mode
|
||||
|
||||
- Remove @ts-strict-ignore comments from vault library files
|
||||
- Fix strict mode violations in password vault functionality
|
||||
- Fix strict mode violations in cipher and folder management
|
||||
- Update vault library tsconfig.json to enable strict mode
|
||||
- Run vault tests to ensure password management works correctly
|
||||
- _Requirements: 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 3.1, 3.2, 3.3_
|
||||
|
||||
- [ ] 3.3 Migrate libs/key-management to strict mode
|
||||
|
||||
- Remove @ts-strict-ignore comments from key-management files
|
||||
- Fix strict mode violations in cryptographic key handling
|
||||
- Fix strict mode violations in encryption/decryption services
|
||||
- Update key-management tsconfig.json to enable strict mode
|
||||
- Run cryptographic tests to ensure security functionality is intact
|
||||
- _Requirements: 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 3.1, 3.2, 3.3_
|
||||
|
||||
- [ ] 3.4 Migrate libs/admin-console to strict mode
|
||||
|
||||
- Remove @ts-strict-ignore comments from admin-console files
|
||||
- Fix strict mode violations in organization management code
|
||||
- Fix strict mode violations in admin features
|
||||
- Update admin-console tsconfig.json to enable strict mode
|
||||
- Run admin console tests to ensure organization features work
|
||||
- _Requirements: 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 3.1, 3.2, 3.3_
|
||||
|
||||
- [ ] 3.5 Migrate libs/billing to strict mode
|
||||
|
||||
- Remove @ts-strict-ignore comments from billing library files
|
||||
- Fix strict mode violations in payment processing code
|
||||
- Fix strict mode violations in subscription management
|
||||
- Update billing library tsconfig.json to enable strict mode
|
||||
- Run billing tests to ensure payment functionality works
|
||||
- _Requirements: 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 3.1, 3.2, 3.3_
|
||||
|
||||
- [ ] 3.6 Migrate libs/tools to strict mode
|
||||
|
||||
- Remove @ts-strict-ignore comments from tools library files
|
||||
- Fix strict mode violations in generator functionality
|
||||
- Fix strict mode violations in import/export features
|
||||
- Update tools library tsconfig.json to enable strict mode
|
||||
- Run tools tests to ensure generator and import/export work
|
||||
- _Requirements: 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 3.1, 3.2, 3.3_
|
||||
|
||||
- [ ] 4. Migrate UI and component libraries
|
||||
- [ ] 4.1 Migrate libs/components to strict mode
|
||||
|
||||
- Remove @ts-strict-ignore comments from components library files
|
||||
- Fix strict mode violations in reusable UI components
|
||||
- Fix strict mode violations in component interfaces and props
|
||||
- Update components library tsconfig.json to enable strict mode
|
||||
- Run component tests to ensure UI components render correctly
|
||||
- _Requirements: 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 3.1, 3.2, 3.3_
|
||||
|
||||
- [ ] 4.2 Migrate libs/angular to strict mode
|
||||
|
||||
- Remove @ts-strict-ignore comments from angular library files
|
||||
- Fix strict mode violations in Angular-specific utilities
|
||||
- Fix strict mode violations in Angular services and directives
|
||||
- Update angular library tsconfig.json to enable strict mode
|
||||
- Run Angular-specific tests to ensure utilities work correctly
|
||||
- _Requirements: 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 3.1, 3.2, 3.3_
|
||||
|
||||
- [ ] 5. Migrate CLI application
|
||||
- [ ] 5.1 Migrate apps/cli to strict mode
|
||||
|
||||
- Remove @ts-strict-ignore comments from CLI application files
|
||||
- Fix strict mode violations in command-line interface code
|
||||
- Fix strict mode violations in CLI command implementations
|
||||
- Update CLI application tsconfig.json to enable strict mode
|
||||
- Run CLI tests and manual testing to ensure commands work
|
||||
- _Requirements: 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 3.1, 3.2, 3.3_
|
||||
|
||||
- [ ] 6. Migrate browser extension
|
||||
- [ ] 6.1 Migrate apps/browser to strict mode
|
||||
|
||||
- Remove @ts-strict-ignore comments from browser extension files
|
||||
- Fix strict mode violations in browser extension background scripts
|
||||
- Fix strict mode violations in content scripts and popup code
|
||||
- Fix strict mode violations in browser-specific APIs usage
|
||||
- Update browser extension tsconfig.json to enable strict mode
|
||||
- Run browser extension tests and manual testing across browsers
|
||||
- _Requirements: 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 3.1, 3.2, 3.3_
|
||||
|
||||
- [ ] 7. Migrate desktop application
|
||||
- [ ] 7.1 Migrate apps/desktop to strict mode
|
||||
|
||||
- Remove @ts-strict-ignore comments from desktop application files
|
||||
- Fix strict mode violations in Electron main process code
|
||||
- Fix strict mode violations in desktop renderer process code
|
||||
- Fix strict mode violations in native integrations
|
||||
- Update desktop application tsconfig.json to enable strict mode
|
||||
- Run desktop tests and manual testing on multiple platforms
|
||||
- _Requirements: 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 3.1, 3.2, 3.3_
|
||||
|
||||
- [ ] 8. Migrate web application
|
||||
- [ ] 8.1 Migrate apps/web to strict mode
|
||||
|
||||
- Remove @ts-strict-ignore comments from web application files
|
||||
- Fix strict mode violations in web vault components
|
||||
- Fix strict mode violations in Angular templates and services
|
||||
- Fix strict mode violations in web-specific routing and guards
|
||||
- Update web application tsconfig.json to enable strict mode
|
||||
- Run web application tests and end-to-end testing
|
||||
- _Requirements: 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 3.1, 3.2, 3.3_
|
||||
|
||||
- [ ] 9. Migrate licensed features
|
||||
- [ ] 9.1 Migrate bitwarden_license/bit-common to strict mode
|
||||
|
||||
- Remove @ts-strict-ignore comments from licensed common files
|
||||
- Fix strict mode violations in enterprise common functionality
|
||||
- Update licensed common tsconfig.json to enable strict mode
|
||||
- Run licensed feature tests to ensure enterprise features work
|
||||
- _Requirements: 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 3.1, 3.2, 3.3_
|
||||
|
||||
- [ ] 9.2 Migrate bitwarden_license/bit-web to strict mode
|
||||
|
||||
- Remove @ts-strict-ignore comments from licensed web files
|
||||
- Fix strict mode violations in enterprise web features
|
||||
- Update licensed web tsconfig.json to enable strict mode
|
||||
- Run enterprise web tests to ensure business features work
|
||||
- _Requirements: 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 3.1, 3.2, 3.3_
|
||||
|
||||
- [ ] 9.3 Migrate bitwarden_license/bit-cli to strict mode
|
||||
|
||||
- Remove @ts-strict-ignore comments from licensed CLI files
|
||||
- Fix strict mode violations in enterprise CLI features
|
||||
- Update licensed CLI tsconfig.json to enable strict mode
|
||||
- Run enterprise CLI tests to ensure business CLI features work
|
||||
- _Requirements: 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 3.1, 3.2, 3.3_
|
||||
|
||||
- [ ] 10. Finalize strict mode configuration
|
||||
- [ ] 10.1 Enable strict mode in base TypeScript configuration
|
||||
|
||||
- Update tsconfig.base.json to set "strict": true
|
||||
- Remove individual strict flags that are now redundant
|
||||
- Ensure all path mappings and compiler options are preserved
|
||||
- _Requirements: 2.1, 2.2, 2.3, 2.4_
|
||||
|
||||
- [ ] 10.2 Remove typescript-strict-plugin dependency
|
||||
|
||||
- Remove typescript-strict-plugin from package.json dependencies
|
||||
- Remove plugin configuration from TypeScript configs
|
||||
- Update build scripts to use native strict mode checking
|
||||
- Update type checking scripts to remove plugin references
|
||||
- _Requirements: 2.1, 2.2, 2.3, 2.4_
|
||||
|
||||
- [ ] 10.3 Update development tooling and documentation
|
||||
|
||||
- Update ESLint configuration to work with strict mode
|
||||
- Update pre-commit hooks to enforce strict mode compliance
|
||||
- Create documentation of common strict mode patterns used
|
||||
- Create guidelines for maintaining strict mode compliance
|
||||
- Document examples of how strict mode violations were resolved
|
||||
- _Requirements: 6.1, 6.2, 6.3_
|
||||
|
||||
- [ ] 11. Final validation and testing
|
||||
- [ ] 11.1 Run comprehensive test suite with strict mode
|
||||
|
||||
- Execute all unit tests across all libraries and applications
|
||||
- Execute all integration tests to ensure no regressions
|
||||
- Run type checking across entire codebase with strict mode
|
||||
- Validate that all applications build successfully
|
||||
- _Requirements: 5.1, 5.2, 5.3, 5.4_
|
||||
|
||||
- [ ] 11.2 Perform manual testing of critical functionality
|
||||
- Test user authentication flows in all applications
|
||||
- Test password management and vault operations
|
||||
- Test browser extension auto-fill functionality
|
||||
- Test desktop application native integrations
|
||||
- Test web vault core features and navigation
|
||||
- Test CLI command functionality
|
||||
- _Requirements: 3.1, 3.2, 3.3, 5.1, 5.2, 5.3, 5.4_
|
||||
Reference in New Issue
Block a user