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

@verifaktura/cius-hr

v0.1.8

Published

Hrvatski CIUS profil (Fiskalizacija 2.0) za verifaktura validator e-računa.

Readme

@verifaktura/cius-hr

Hrvatski CIUS profil (Fiskalizacija 2.0) za verifaktura validator eRačuna.

npm install verifaktura @verifaktura/cius-hr
import { validate } from "verifaktura";
import "@verifaktura/cius-hr";   // registrira profil

const report = await validate(xml, { lang: "hr" });
// report.profiles -> [{ id: "en16931", ... }, { id: "hr", version: "2026-03-15", ... }]

Profil se primjenjuje isključivo na UBL dokumente s oznakom specifikacije:

urn:cen.eu:en16931:2017#compliant#urn:mfin.gov.hr:cius-2025:1.0#conformant#urn:mfin.gov.hr:ext-2025:1.0

Izvezena je kao HR_CUSTOMIZATION_ID. Odabir profila je automatski, prema cbc:CustomizationID dokumenta.

Opis na stranici Porezne uprave sadrži fusnotu koja se pri kopiranju uvuče u string i daje ext[1]2025 umjesto ext-2025. Vrijednost u ovom paketu preuzeta je iz samog schematrona (pravilo HR-BR-5).

Artefakti

U izvornom repozitoriju ih nema — npm run prepare:sef preuzima ZIP s porezna.gov.hr (dokument 197) i kompilira ga kroz ISO Schematron lanac. Za razliku od CEN-a, Porezna uprava isporučuje sirovi .sch, ne prekompilirani XSLT. U objavljeni npm paket ulazi prekompilirani rezultat, da paket radi bez mreže.

Što hrvatski profil traži povrh EN 16931

| Pravilo | Zahtjev | Polje u @verifaktura/build | |---|---|---| | HR-BR-2 | vrijeme izdavanja (HR-BT-2), hh:mm:ss | issueTime | | HR-BR-37 | oznaka operatera (HR-BT-4) | seller.contact.name | | HR-BR-9 | OIB operatera (HR-BT-5) s kontrolnom znamenkom | seller.contact.id | | HR-BR-25, HR-BR-CL-2 | klasifikacija artikla po KPD 2025, listID="CG", oblik 62.10.11 | line.classification | | HR-BR-34 | oznaka procesa (BT-23): P1–P12 ili P99:<oznaka> | profileId | | HR-BR-53 | OIB prodavatelja mora proći kontrolu | seller.vatId (prefiks HR je dopušten) | | HR-BR-4 | datum dospijeća kad je iznos za plaćanje > 0 | dueDate | | HR-BR-S-1 | PDV ID kupca kad je kategorija „S" | buyer.vatId |

Ispravnost OIB-a možeš provjeriti prije gradnje dokumenta:

import { isValidOib } from "@verifaktura/build";
isValidOib("12345678903");   // true

Sukob s CEN sintaksnim pravilima

Hrvatski CIUS traži elemente koje CEN označava s „should not include":

| CEN pravilo | Element | Traži ga | |---|---|---| | UBL-CR-006 | cbc:IssueTime | HR-BR-2 | | UBL-CR-200 | cac:SellerContact | HR-BR-37, HR-BR-9 |

Profil ih deklarira kroz overrides, pa se spuštaju na info uz napomenu koji ih profil nadjačava. Ne skrivaju se — ispravan hrvatski eRačun bi inače uvijek vraćao dva upozorenja, a upozorenje koje uvijek gori korisnik nauči ignorirati.

Licencija

Kod je pod Apache-2.0.

Paket sadrži prekompilirani hrvatski schematron (sef/hr-cius-ext-ubl.sef.json), vlasništvo Ministarstva financija — Porezne uprave RH. Sadržaj se prenosi uz navođenje izvora, u skladu s uvjetima porezna.gov.hr. Vidi NOTICE.