tee-skin-renderer
v0.0.7
Published
<p align="center"><b>tee-skin-renderer</b> - Teeworlds / DDNet skin renderer for you HTML pages</p>
Downloads
203
Readme
Getting Started
Usage (UMD)
<head>
<!-- ... -->
<link rel="preload" as="image" href="https://skins.ddnet.org/skin/community/default.png">
<link rel="stylesheet" href="https://unpkg.com/tee-skin-renderer/dist/tee-skin-renderer.css">
<!-- ... -->
</head>
<body>
<!-- ... -->
<div
class="tee"
data-skin="https://skins.scrumplex.net/skin/pinky.png"
>
</div>
<!-- ... -->
<div
class="tee"
data-skin="https://skins.scrumplex.net/skin/pinky.png"
data-color-body="5498880"
data-color-feet="3079936"
>
</div>
<!-- ... -->
<div
class="tee"
data-skin="https://skins.scrumplex.net/skin/pinky.png"
data-color-body="5498880"
data-color-feet="3079936"
data-use-custom-color="false"
>
</div>
<!-- ... -->
<script src="https://unpkg.com/tee-skin-renderer/dist/tee-skin-renderer.umd.js"></script>
</body>
Usage (ESM)
npm install tee-skin-renderer --save
import { createAsync } from 'tee-skin-renderer';
import 'tee-skin-renderer/css';
createAsync({ skinUrl: 'https://skins.scrumplex.net/skin/pinky.png' }).then((container) => {
document.body.appendChild(container);
});
import { init } from 'tee-skin-renderer';
import 'tee-skin-renderer/css';
init();
License
tee-skin-renderer is licensed under a CC0-1.0 License.