Get started with tinycon CDN

MIT licensed

Tinycon is a lightweight library for creating system tray notifications on Windows and Mac.

Tags:
  • favicon
  • Tinycon

Stable version

Copied!

How to start using tinycon CDN


<!DOCTYPE html>
<html>
<head>
    <title>Get started with tinycon CDN - cdnhub.io</title>
    <script src="https://cdn.cdnhub.io/tinycon/0.6.5/tinycon.min.js"></script>
</head>
<body>
    <button id="convert-btn">Convert</button>
    <script>
        document.getElementById('convert-btn').addEventListener('click', () => {
            const input = 'Hello, World!';
            TinyCON.toFont('💡').then((font) => {
                const span = document.createElement('span');
                span.textContent = TinyCON.textToImage(input, {
                    fontSize: 32,
                    width: 200,
                    height: 100,
                    backgroundColor: '#fff',
                    color: '#000',
                    fontFamily: font.family,
                });
                document.body.appendChild(span);
            });
        });
    </script>
</body>
</html>
Copied!
Copied!

All versions