Is there a relative URL format for the link rel=stylesheet href=URL that works in both jsdom and browsers?

17 views
Skip to first unread message

Jonathan Pool

unread,
Jul 15, 2019, 4:55:07 PM7/15/19
to jsdom
If I include a link element with rel="stylesheet" href="styles.css", a browser finds and loads that CSS file. But jsdom does not.

If I insert "file://" before the filename, then jsdom finds and loads the CSS file. But the browser does not.

So what do I need to do? Must I include 2 link elements, one with each URL format?

I'm using jsdom 14.0.0.

Domenic Denicola

unread,
Jul 15, 2019, 4:56:55 PM7/15/19
to js...@googlegroups.com

Have you set the URL of your JSOM instance?

--
You received this message because you are subscribed to the Google Groups "jsdom" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jsdom+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jsdom/6928cf41-6ada-49dc-b4d8-c2d35afaaa8b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages