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/JS external resources loaded before the assets #335

Merged
merged 3 commits into from
Aug 20, 2018
Merged

Conversation

T4rk1n
Copy link
Contributor

@T4rk1n T4rk1n commented Aug 14, 2018

Ensure CSS/JS external resources are loaded before the assets, Fix #331.

@T4rk1n T4rk1n requested a review from rmarren1 August 14, 2018 22:11
@rmarren1
Copy link
Contributor

Looks good! 💃

@T4rk1n T4rk1n force-pushed the css-include-order branch 3 times, most recently from d9e2a72 to ec4992f Compare August 20, 2018 15:27
@T4rk1n T4rk1n force-pushed the css-include-order branch from ec4992f to 0e46327 Compare August 20, 2018 15:30
@T4rk1n T4rk1n merged commit 4d93652 into master Aug 20, 2018
@T4rk1n T4rk1n deleted the css-include-order branch August 20, 2018 15:50
@eddy-ojb
Copy link

eddy-ojb commented Sep 8, 2018

Is this feature optionally enforced?

I am looking to apply Bootstrap popovers in order to provide descriptions to new users on a per graph basis since some of my users may be new to some graph types. In order to use a popover on a regular html page, a bit of jquery os required after the document is ready as described here:

https://getbootstrap.com/docs/4.0/components/popovers/

Before I go down this road, does this conflict with loading the js before the assets? would you expect this to be feasible in Dash? I see the html components facilitate this, so i dont see why not..

@rmarren1
Copy link
Contributor

rmarren1 commented Sep 9, 2018

@eddy-ojb I've attempted to use JQuery before and it did not work too well. Dash is built on react, and mixing react and jQuery gets tricky at times. Best bet is probably to use React to do popovers (e.g. make a custom component library). I think the easiest route would be to build on the dash-core-components Graph component and add popover functionality.

Some links:
'Official' info on using JQuery with react - https://reactjs.org/docs/integrating-with-other-libraries.html
Reasons to not use JQuery and just use react - https://discuss.reactjs.org/t/jquery-with-react/683
React-Strap -- boostrap-like components in React - https://reactstrap.github.io/components/popovers/

@eddy-ojb
Copy link

eddy-ojb commented Sep 9, 2018

Thanks for the tip @rmarren1. Rather than waste my time with jquery I will explore making my own component. I am a javascript noob and so I expect this to take a while but will share afterwards.

HammadTheOne pushed a commit to HammadTheOne/dash that referenced this pull request May 28, 2021
HammadTheOne pushed a commit that referenced this pull request Jul 23, 2021
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