Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

How do i put a link into the pre-made head tag? #833

Unanswered
rn3r asked this question in Question
Discussion options

I dont want to create a div that holds the head that holds the css, i would like a way for me to automatically put it in the head so everything loads normally.

You must be logged in to vote

Replies: 2 comments 3 replies

Comment options

Related to comments in #832

You must be logged in to vote
3 replies
Comment options

i just looked through that and it doesnt seem to be what im looking for. I'm trying to preset the head to contain a link tag to my css

Comment options

TLDR: Populating the HTML <head> is currently not possible within IDOM's python interface.

It is however, possible using the javascript components interface and using react-helmet.

Comment options

Also, related to #725

Comment options

This has been requested a number of times. While certain things can be done by using script() to change the page title after the initial load, this is sub-optimal. I've begun working on a solution to this here: #835

The approach will be to allow users to configure the <head/> element with a head option for each of the built-in backend at startup. The interface will look something like:

from starlette import Starlette
from idom import component, html
from idom.backend.starlette import configure, Options
app = Starlette()
@component
def example_app():
 ...
configure(app, example_app, Options(head=html.head(...)))
You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet

AltStyle によって変換されたページ (->オリジナル) /