fastify / fastify/fastify-cli

Options propagation

Open
#841 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
733
Forks
177
Avg merge
1d 20h
Merged PRs (30d)
3

Description

### Prerequisites

- [x] I have written a descriptive issue title
- [x] I have searched existing issues to ensure the issue has not already been raised

### Issue

By default, the generated templates [pass `options` to the autoloader](https://github.com/fastify/fastify-cli/blob/main/templates/app-ts-esm/src/app.ts#L31), which are then propagated to all loaded plugins.
This behavior can cause errors with external plugins if they receive unexpected properties or values in `options`

Here’s an example of the issue in the demo repository:
https://github.com/fastify/demo/issues/119

Should we continue to do this?
Or simply add doc to prevent this kind of errors in the future?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.