License key
horee-grid is commercial software. Using it on a production address requires a key issued by horeetec.com. The key is checked inside the grid without an internet connection. No usage data is sent anywhere.
Setting the key
import { setLicenseKey } from 'horee-grid'
setLicenseKey('eyJ2IjoxLCJjIjoi…') // once at app start- It does not matter whether you call it before or after creating grids. Existing grids are checked again.
- You may write the key directly in your code. It is bound to domains and does not work on other addresses. Putting it in a build environment variable makes it easy to separate development and production.
What the key contains
| Item | Contents |
|---|---|
| Customer | The company that bought it |
| Domains | Addresses where it can be used. erp.example.com means only that address; *.example.com means example.com and every address under it |
| Expiry date | Usable until this date. Perpetual licenses use 9999-12-31 |
| Update deadline | Versions released up to this date can be used. Only in perpetual licenses (1 year after purchase, extended by maintenance renewals) |
The key is signed with horeetec.com's private key. Changing a single character makes it invalid.
Addresses that need no key
During development you do not need a key.
localhost,127.0.0.1,[::1]*.localhost(e.g.erp.localhost)
When the key does not match
The grid does not stop. Every feature keeps working, and a notice appears in the bottom-right corner of the grid. The reason is logged to the console once. The notice follows the grid's locale.
Notice (en) | Reason (reason) | What to do |
|---|---|---|
| No license key | none | Call setLicenseKey |
| Malformed license key | format | Check that the key was not cut or extended |
| Invalid license key | signature | Check that you used the key exactly as received |
| License key is not for this address | domain | Get a new key that includes this address |
| License has expired | expired | Renew the key |
| This version was released after this key’s update period | version | Go back to a version released within the period, or renew maintenance and get a new key |
| License cannot be checked on this address (not a secure connection) | unsupported | Open it over https. Signature checks only work on secure connections |
Checking the state
import { getLicenseState } from 'horee-grid'
const s = await getLicenseState()
// { ok: true, reason: 'ok', customer: 'Example Inc.', expires: '9999-12-31', updates: '2027-12-01' }
if (!s.ok) console.log(s.reason)You can use it, for example, to alert an administrator 30 days before expiry.
Issuing and renewing keys
Prices and how to buy are on the Pricing page. If you change domains or renew maintenance, you get a new key. Contact [email protected].
Terms of use
Governed by the LICENSE file. In short: you may not copy, modify, distribute or resell it without written permission from the copyright holder (horeetec.com). Use within the buying company's systems is free within the key's domains and period.