Skip to content

Conversation

@Gregcop1
Copy link
Contributor

@Gregcop1 Gregcop1 commented May 20, 2019

To avoid CORS rejection when using client-generator we should enable this kind of origins

For info: regex battery test -> https://regex101.com/r/3CUlV8/2

Q A
Bug fix? yes
New feature? no
BC breaks? no
Deprecations? no
Tests pass? not sure of this (I can't install project ATM)
License MIT

To avoid CORS rejection when using client-generator we should enable this kind of origins
@dunglas dunglas merged commit 6cac412 into api-platform:master May 20, 2019
@Gregcop1 Gregcop1 deleted the fix-cors branch May 20, 2019 22:01
debug: '0'
secret: ""
corsAllowOrigin: "^https?://.*?\\.api-platform\\.com$"
corsAllowOrigin: "^https?://(.*?api-platform\\.com|localhost(?::[0-9]+)?)$"
Copy link
Contributor

@teohhanhui teohhanhui May 21, 2019

Choose a reason for hiding this comment

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

Now fakeapi-platform.com is allowed! 😝

https://regex101.com/r/EA7Gzu/2

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Now? It was already possible.

Copy link
Member

Choose a reason for hiding this comment

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

No it wasn't because of the \. part. Indeed we must add it back.

Copy link
Contributor

@teohhanhui teohhanhui May 21, 2019

Choose a reason for hiding this comment

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

Copy link
Member

Choose a reason for hiding this comment

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

We don't call the demo from api-platform.com, so https://regex101.com/r/EA7Gzu/5 is enough.

Copy link
Contributor

Choose a reason for hiding this comment

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

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants