Skip to content

Conversation

@weirdwater
Copy link
Collaborator

Checklist

  • Contains unit tests ❌
  • Contains breaking changes ✅
  • Compatible with: Any
  • Did you update version and changelog? ✅
  • PR title properly formatted ([XX-000]: description)? ✅

This PR contains

  • Bug fix
  • Feature
  • Refactor
  • Documentation
  • Other (describe)

What is the purpose of this PR?

Widget names are only allowed to contain lower and uppercase letters. This is checked by the generator when the developer is prompted for a widget name. However, this validation is never done during bundling. Since Studio Pro assumes this, a widget which had its name changed after generation could cause the deployment of an app to fail.

Relevant changes

A check was added to the bundler when the widgetName is retrieved from the widget's package.json.

What should be covered while testing?

  • Widgets with allowed names are able to build.
  • Widgets with unallowed names (including characters that are not [a-zA-Z]) cause the build to fail.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants