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

showcase: ExampleViewer does not take into account the baseUrl while fetching the example files #575

Closed
christophercr opened this issue Jul 31, 2018 · 0 comments · Fixed by #584

Comments

@christophercr
Copy link
Collaborator

christophercr commented Jul 31, 2018

I'm submitting a...


[ ] Regression (a behavior that used to work and stopped working in a new release)
[X] Bug report  
[ ] Feature request
[ ] Documentation issue or request
[ ] Support request => Please do not submit support request here, instead see https://github.com/NationalBankBelgium/stark/blob/master/CONTRIBUTING.md#got-a-question-or-problem

Current behavior

The ExampleViewer does not show any example files due to an Http error while fetching the files:

GET https://stark.nbb.be/assets/examples/keyboard-directives/on-enter-key-directive.html 404 ()

The problem occurs because the Http request triggered by the FileService to fetch the files does not take into account the baseUrl of the app when this is deployed on GitHub Pages.

Expected behavior

The FileService should fetch the files targetting the correct Http, for example in the latest Showcase:

GET https://stark.nbb.be/showcase/latest/assets/examples/keyboard-directives/on-enter-key-directive.html 

Minimal reproduction of the problem with instructions

Go on Stark showcase and go to any demo page.
In the demo page click on the "View source" button of the ExampleViewer component.
The example files will not be displayed and an error will be shown in the console.

Environment


Angular version: X.Y.Z
Stark version: 10.0.0-alpha.4
@christophercr christophercr added this to the 10.0.0-alpha.5 milestone Jul 31, 2018
@christophercr christophercr changed the title showcase: FileService does not take into account the baseUrl while fetching the files showcase: ExampleViewer does not take into account the baseUrl while fetching the example files Jul 31, 2018
@christophercr christophercr self-assigned this Jul 31, 2018
christophercr referenced this issue in christophercr/stark Aug 1, 2018
…g the right url. Rename title input to prevent weird tooltip.

ISSUES CLOSED: #575 #580
christophercr referenced this issue in christophercr/stark Aug 2, 2018
…g the right url. Rename title input to prevent weird tooltip.

ISSUES CLOSED: #575 #580
christophercr referenced this issue in christophercr/stark Aug 2, 2018
…g the right url. Rename title input to prevent weird tooltip.

ISSUES CLOSED: #575 #580
christophercr referenced this issue in christophercr/stark Aug 3, 2018
…g the right url. Rename title input to prevent weird tooltip.

ISSUES CLOSED: #575 #580
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
1 participant