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

CSS styles assigned incorrectly when accessing subpage directly #11

Closed
nai888 opened this issue May 9, 2018 · 2 comments · Fixed by #567
Closed

CSS styles assigned incorrectly when accessing subpage directly #11

nai888 opened this issue May 9, 2018 · 2 comments · Fixed by #567

Comments

@nai888
Copy link
Collaborator

nai888 commented May 9, 2018

Langua Version

0.1.3

Expected Behavior

Load each page's styles accurately, even if accessing a subpage directly.

Actual Behavior

When loading a subpage directly, the CSSinJS classes are assigned incorrectly, which causes elements to have the wrong appearance.

Steps to Reproduce

Load a subpage directly (e.g. go straight to https://nai888.github.io/langua/gen without loading the homepage first).

Note: since react-snap doesn't come into play until the build process, the issue only happens on the built static site, not on the development server.

Observations

This is an issue with react-snap generating a static HTML file with predefined CSS classes and then CSSinJS dynamically assigning the CSS classes to elements on the page. This is why loading the home page first works, because the elements are rendered in the "correct order" for the classes to be dynamically assigned to elements in the correct order.

@nai888 nai888 added the bug label May 9, 2018
@nai888 nai888 self-assigned this May 9, 2018
nai888 added a commit that referenced this issue May 10, 2018
Remove react-snap from the build process for now, since it is currently assigning CSS classes incorrectly (see issue #11). Updated CHANGELOG with recent changes.
nai888 added a commit that referenced this issue May 10, 2018
Add toast notifications explanation to CHANGELOG. Add link to issue #11 about incorrect CSS class assignment.
@nai888 nai888 removed their assignment May 21, 2018
@nai888
Copy link
Collaborator Author

nai888 commented Sep 29, 2018

As of v0.1.4, react-snap has been removed from the project until this can be solved. React-snap isn't critical to the project, so getting this solved is currently low priority.

@nai888 nai888 mentioned this issue Oct 11, 2020
@nai888
Copy link
Collaborator Author

nai888 commented Oct 11, 2020

Fixed by #567

@nai888 nai888 closed this as completed Oct 11, 2020
@nai888 nai888 linked a pull request Oct 19, 2020 that will close this issue
@nai888 nai888 moved this to Closed in Bug and Feature Triage Mar 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Development

Successfully merging a pull request may close this issue.

1 participant