
Security News
ECMAScript 2025 Finalized with Iterator Helpers, Set Methods, RegExp.escape, and More
ECMAScript 2025 introduces Iterator Helpers, Set methods, JSON modules, and more in its latest spec update approved by Ecma in June 2025.
React va TypeScript ilovalarida raqamli imzolar bilan ishlash uchun oddiy paket.
use-eimzo
— bu veb-ilovalarda E-IMZO raqamli imzo tizimi bilan ishlashni osonlashtiradigan React hook va provayder. U sertifikatlarni yuklash, PKCS7 yaratish va skript injeksiya jarayonlarini boshqarishni soddalashtiradi.
Paketni npm yoki yarn orqali o'rnating:
npm install use-eimzo
yoki
yarn add use-eimzo
EImzoProvider
komponenti yordamida ilovangizni o'rab oling, bu E-IMZO skriptining to'g'ri yuklanishini ta'minlaydi.
import { EImzoProvider } from 'use-eimzo'
function App() {
return (
<EImzoProvider>
<YourComponent />
</EImzoProvider>
)
}
useEImzo
hookidan foydalanib, E-IMZO funksiyalariga kirish mumkin.
import { useEImzo } from 'use-eimzo'
import { useEffect, useState } from 'react'
function YourComponent() {
const { listAllKey, createPkcs7 } = useEImzo()
const [keys, setKeys] = useState([])
useEffect(() => {
listAllKey().then(setKeys).catch(console.error)
}, [])
const handleSign = async (cert) => {
try {
const signedData = await createPkcs7(cert)
console.log('Imzolangan ma’lumot:', signedData)
} catch (error) {
console.error('Imzolashda xatolik:', error)
}
}
return (
<div>
<h2>Mavjud sertifikatlar</h2>
{keys.map((cert, index) => (
<div key={index}>
<p>{cert.CN}</p>
<button onClick={() => handleSign(cert)}>Imzolash</button>
</div>
))}
</div>
)
}
EimzoDefaultItem
komponentidan sertifikat tafsilotlarini ko'rsatish uchun foydalaning.
import { EimzoDefaultItem } from 'use-eimzo'
function CertificateList({ data }) {
return (
<div>
{data.map((cert, index) => (
<EimzoDefaultItem key={index} data={cert} />
))}
</div>
)
}
MIT
FAQs
React va TypeScript ilovalarida raqamli imzolar bilan ishlash uchun oddiy paket.
The npm package use-eimzo receives a total of 2 weekly downloads. As such, use-eimzo popularity was classified as not popular.
We found that use-eimzo demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
ECMAScript 2025 introduces Iterator Helpers, Set methods, JSON modules, and more in its latest spec update approved by Ecma in June 2025.
Security News
A new Node.js homepage button linking to paid support for EOL versions has sparked a heated discussion among contributors and the wider community.
Research
North Korean threat actors linked to the Contagious Interview campaign return with 35 new malicious npm packages using a stealthy multi-stage malware loader.