Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Add old names to platform for compatibility #9088

Merged
merged 3 commits into from Dec 28, 2020

Conversation

NathanaelA
Copy link
Contributor

PR Checklist

What is the current behavior?

We somehow renamed Platform.screen & Platform.device to Platform.Screen and Platform.Device in the Mono-Repo transition. This breaks plugins and applications, including all versions of NS-Theme's 2.x. This also breaks all examples and the current documentation.

What is the new behavior?

Adds a simple compatibility classes so that Platform.screen and Platform.device both point to the upper case version, to allow every plugin and use of this to work. The new name Platform.Screen and Platform.Device still work as we are using them in other places...

@cla-bot cla-bot bot added the cla: yes label Dec 5, 2020
Copy link
Member

@rigor789 rigor789 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks fine to me, just missing the change in the definitions (index.d.ts)

@farfromrefug
Copy link
Collaborator

Really good idéal to bring this back !

@rigor789 rigor789 added this to the 7.1 milestone Dec 20, 2020
@rigor789
Copy link
Member

@NathanaelA could you make the same change in the index.d.ts file?

@rigor789 rigor789 merged commit 4204ac8 into master Dec 28, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants