rt-link-loader example
It tells you how to work rt-link-loader
author(s):
Toshiyuki Ogawa
by Toshyuki Ogawa
HTML
<!DOCTYPE html>
<html>
<head>
<link href="https://unpkg.com/@oc-soft/rt-link-loader/exp/main.css" rel="stylesheet">
<script src="https://unpkg.com/@oc-soft/rt-link-loader/exp/lib.js"></script>
</head>
<body>
<h1>main.css href is</h1>
<p></p>
</body>
</html>
<!-- vi: se ts=2 sw=2 et: -->
JavaScript
window.addEventListener('load', event => {
const pTags = document.getElementsByTagName('p')
pTags[0].innerText = mainCssLib.mainCss.href
//pTags[0].innerText = mainCssLib.mainCss.cssRules[0].cssText
// Unfoturnately I can not get mainCss.rules
})
// vi: se ts=2 sw=2 et: