cypress-svelte-unit-test
cypress-svelte-unit-test copied to clipboard
Support all options of component ctor
Bug:
The component constructor can take several options, not just data: currently there is data, store and slots, and potentially there will be more.
The fact that the second parameter to mount() is used as data rather than as the options might be considered a bug, because it does not match the component ctor, it makes it difficult to support the current options and to add more options in the future.
Suggestion: change the mount(Component, data) api to mount(Component, options) and let options have data, store and slots etc. attributes.
Great idea
Sent from my iPhone
On Feb 18, 2018, at 12:10, Dietrich Schulten [email protected] wrote:
Bug: The component constructor can take several options, not just data: currently there is data, store and slots, and potentially there will be more. The fact that the second parameter is used as data rather than as the options might be considered a bug, because it makes it difficult to add more options in the future. Suggestion: change the mount(Component, data) api to mount(Component, options) and let options have data, store and slots etc. attributes.
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or mute the thread.