npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@kawanua/license-sdk

v1.1.1

Published

Drop-in SDK untuk klien yang menggunakan lisensi Kawanua.

Readme

@kawanua/license-sdk

SDK resmi untuk klien yang menggunakan sistem lisensi Kawanua. SDK ini menyediakan metode verifikasi lisensi berbasis JWT (RS256) di sisi klien dengan fitur auto-branding dan kontrol akses fitur yang dinamis.

Fitur Utama

  • Verifikasi Aman: Memverifikasi token JWT lisensi menggunakan RS256.
  • Dukungan Multi-Environment: Mendukung browser (via <script>), CommonJS, dan ESM.
  • Kontrol Fitur: Mendukung limitasi fitur berdasarkan plan (Starter, Professional, Enterprise).
  • Auto-Branding: Secara otomatis menyuntikkan atau menyembunyikan elemen "Powered by Kawanua" sesuai ketentuan lisensi.
  • Auto-Refresh: Mekanisme pembaruan token otomatis sebelum masa berlaku habis.

Instalasi

via CDN (Browser)

Tambahkan script berikut sebelum tag </body>:

<script src="https://cdn.kawanua.id/sdk/license.min.js"></script>

via NPM

npm install @kawanua/license-sdk

Penggunaan

Inisialisasi

import { KawanuaLicense } from '@kawanua/license-sdk';

KawanuaLicense.init({
  token: 'YOUR_JWT_TOKEN',
  onRefresh: async () => {
    // Implementasi untuk fetch token baru dari server kamu
    const res = await fetch('/api/license/refresh');
    const { token } = await res.json();
    return token;
  },
  onReady: (state) => {
    console.log('Lisensi aktif, plan:', state.plan);
  },
  onError: (err) => {
    console.error('Inisialisasi gagal:', err.message);
  }
});

React

import { useEffect, useState } from 'react';

function App() {
  const [license, setLicense] = useState(null);

  useEffect(() => {
    KawanuaLicense.init({
      token: window.__LICENSE_TOKEN__, // inject dari server-side rendering
      onReady: (state) => setLicense(state),
    });
    return () => KawanuaLicense.destroy();
  }, []);

  if (!license) return <p>Memverifikasi lisensi...</p>;

  return (
    <div>
      <h1>Dashboard</h1>
      {KawanuaLicense.can('api_access') && <ApiSection />}
      <p>Plan: {license.plan}</p>
    </div>
  );
}

Vue 3

import { onMounted, onUnmounted } from 'vue';

onMounted(() => {
  KawanuaLicense.init({
    token: import.meta.env.VITE_LICENSE_TOKEN,
    onReady: (state) => { license.value = state; },
  });
});
onUnmounted(() => KawanuaLicense.destroy());

Vanilla JS

<script src="https://cdn.kawanua.id/sdk/license.min.js"></script>
<script>
  KawanuaLicense.init({
    token: document.querySelector('meta[name="license-token"]').content,
    onReady: (state) => {
      if (!KawanuaLicense.can('white_label')) {
        document.getElementById('footer-branding').style.display = 'block';
      }
    },
  });
</script>

Mengecek Akses Fitur

Setelah inisialisasi berhasil, kamu bisa mengecek apakah sebuah fitur diperbolehkan:

// Mengecek boolean
if (KawanuaLicense.can('api_access')) {
  // Tampilkan fitur API
}

// Mendapatkan nilai (misal: limit jumlah user)
const maxUsers = KawanuaLicense.get('max_users');

Referensi Plan

SDK secara otomatis mengatur batasan fitur berdasarkan plan:

| Fitur | Starter | Professional | Enterprise | | :--- | :---: | :---: | :---: | | Remove Branding | ❌ | ✅ | ✅ | | Custom Domain | ❌ | ❌ | ✅ | | API Access | ❌ | ✅ | ✅ | | Max Users | 5 | 50 | ∞ |

Lisensi

ISC


Dibuat oleh Kawanua Indo Digital