Skip to content

Comments

refactor(dev): introduce DevWatchOptions for enhanced file watching configuration#6059

Closed
hyf0 wants to merge 1 commit intographite-base/6059from
09-08-refactor_dev_introduce_devwatchoptions_for_enhanced_file_watching_configuration_moves_watcher-related_options_usepolling_pollinterval_from_devoptions_into_a_standalone_devwatchoptions_struct_interface_providing_better_organizati
Closed

refactor(dev): introduce DevWatchOptions for enhanced file watching configuration#6059
hyf0 wants to merge 1 commit intographite-base/6059from
09-08-refactor_dev_introduce_devwatchoptions_for_enhanced_file_watching_configuration_moves_watcher-related_options_usepolling_pollinterval_from_devoptions_into_a_standalone_devwatchoptions_struct_interface_providing_better_organizati

Conversation

@hyf0
Copy link
Member

@hyf0 hyf0 commented Sep 8, 2025

Moves watcher-related options (usePolling, pollInterval) from DevOptions
into a standalone DevWatchOptions struct/interface, providing better
organization and type safety for file watching configuration.

Changes:

  • Create DevWatchOptions struct with optional usePolling and pollInterval fields
  • Update DevOptions to include optional watch field of type DevWatchOptions
  • Maintain backward compatibility in normalized options structure
  • Update TypeScript API, NAPI bindings, and Rust core layers
  • Add proper exports for new types in experimental index
  • Update integration points and conversion logic
  • Remove redundant exports from dev/index.ts to fix linting

This change enables cleaner API usage:

const devEngine = await dev(input, output, {
  onHmrUpdates: (updates) => console.log(updates),
  watch: {
    usePolling: true,
    pollInterval: 500
  }
});

🤖 Generated with Claude Code

Co-Authored-By: Claude [email protected]

…onfiguration

Moves watcher-related options (usePolling, pollInterval) from DevOptions
into a standalone DevWatchOptions struct/interface, providing better
organization and type safety for file watching configuration.

Changes:
- Create DevWatchOptions struct with optional usePolling and pollInterval fields
- Update DevOptions to include optional watch field of type DevWatchOptions
- Maintain backward compatibility in normalized options structure
- Update TypeScript API, NAPI bindings, and Rust core layers
- Add proper exports for new types in experimental index
- Update integration points and conversion logic
- Remove redundant exports from dev/index.ts to fix linting

This change enables cleaner API usage:
```typescript
const devEngine = await dev(input, output, {
  onHmrUpdates: (updates) => console.log(updates),
  watch: {
    usePolling: true,
    pollInterval: 500
  }
});
```

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <[email protected]>
Copy link
Member Author

hyf0 commented Sep 8, 2025

Warning

This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
Learn more


How to use the Graphite Merge Queue

Add the label graphite: merge to this PR to add it to the merge queue.

You must have a Graphite account in order to use the merge queue. Sign up using this link.

An organization admin has enabled the Graphite Merge Queue in this repository.

Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue.

This stack of pull requests is managed by Graphite. Learn more about stacking.

@hyf0 hyf0 changed the base branch from 09-08-refactor_dev_introduce_devwatchoptions_for_enhanced_file_watching_configuration to graphite-base/6059 September 8, 2025 07:20
@hyf0
Copy link
Member Author

hyf0 commented Sep 8, 2025

Closing this PR as the changes have been folded into the original PR #6057

@hyf0 hyf0 closed this Sep 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant