fix safety issue & apply readability suggestions #144
Annotations
2 errors
src/parser/analyse/story/attributes.test.ts > getStringValueFromAttribute > throws error when a `<Story />` 'name' attribute value is not a string:
src/parser/analyse/story/attributes.test.ts#L37
Error: Snapshot `getStringValueFromAttribute > throws error when a `<Story />` 'name' attribute value is not a string 1` mismatched
- Expected
+ Received
[SB_SVELTE_CSF_PARSER_ANALYSE_STORY_0001 (AttributeNotStringError): In the stories file: <path not specified>
- A '<Story name="<unspecified Story name>" />' has a prop 'name' whose value must be a static literal string.
+ A '<Story name="undefined" />' has a prop 'name' whose value must be a static literal string.
More info: https://github.com/storybookjs/addon-svelte-csf/blob/v4.1.2/ERRORS.md#SB_SVELTE_CSF_PARSER_ANALYSE_STORY_0001
]
❯ src/parser/analyse/story/attributes.test.ts:37:8
|
Test
Process completed with exit code 1.
|