Description
Describe the bug
A clear and concise description of what the bug is.
When working with typescript, the following typescript alert is displayed if no easing param is specified:
Argument of type '{ delay: number; duration: number; x: number; y: number; opacity: number; }' is not assignable to parameter of type 'FlyParams'.
Property 'easing' is missing in type '{ delay: number; duration: number; x: number; y: number; opacity: number; }' but required in type 'FlyParams'.ts(2345)
Offending code:
<div transition:fly="{{delay: 250, duration: 300, x: 0, y: -100, opacity: 0.5}}"
[...]
To get rid of the alert, you have to specify a value for easing, like this:
<div transition:fly="{{delay: 250, duration: 300, x: 0, y: -100, opacity: 0.5, easing: sineInOut}}"
[...]
To match the svelte tutorial it should be optional
Information about your Svelte project:
-
Your browser and the version: (e.x. Chrome 52.1, Firefox 48.0, IE 10)
any browser -
Your operating system: (e.x. OS X 10, Ubuntu Linux 19.10, Windows XP, etc)
-
Svelte version (Please check you can reproduce the issue with the latest release!)
"svelte": "^3.0.0",
- Whether your project uses Webpack or Rollup
rollup
Severity
How severe an issue is this bug to you? Is this annoying, blocking some users, blocking an upgrade or blocking your usage of Svelte entirely?
barely annoying