
Security News
/Research
Fake Corepack Site Distributes Infostealer and Proxyware to Developers
A fake corepack.org site is impersonating the Node.js tool and delivers an infostealer and proxyware to developers who download it.
twilight.db
Advanced tools
TwilightDB, verilerinizi farklı formatlarda depolamak ve yönetmek için esnek bir Node.js modülüdür. Bu modül sayesinde JSON, MySQL, BSON ve YAML gibi veritabanı formatlarını destekleyerek projenize uygun veri depolama seçenekleri sunar.
const { TwilightDB } = require('twilight.db');
// Örnek kullanım
const db = new TwilightDB('mydata.json', 'json');
/**
BSON formatında veritabanı
const dbBson = new TwilightDB('mydata.bson', 'bson');
**/
/**
YAML formatında veritabanı
const dbYaml = new TwilightDB('mydata.yaml', 'yaml');
**/
/**
Mysql formatında veritabanı
const mysql = require('mysql'); // twilight.db nin hemen altına yapıştırcan
const config = {
host: 'localhost', // MySQL sunucusunun adresi
port: 3306, // Bağlantı noktası
user: 'kullaniciadi', // MySQL kullanıcı adı
password: 'sifre', // MySQL kullanıcı şifresi
database: 'veritabani', // Bağlanmak istediğiniz veritabanının adı
};
const connection = mysql.createConnection(config);
connection.connect((err) => {
if (err) {
console.error('Bağlantı hatası:', err);
} else {
console.log('MySQL sunucusuna bağlandı!');
// Bağlantı başarılı bir şekilde kurulduğunda burada işlemlerinizi yapabilirsiniz.
}
});
**/
// Veri oluşturma
db.create('name', 'Luppux');
db.create('age', 25);
// Veri okuma
console.log(db.read('name')); //
// Veri güncelleme
db.update('age', 30);
console.log(db.read('age')); // 30
// Veri silme
db.delete('age');
console.log(db.read('age')); // undefined
// Veri sorgulama
const results = db.query((key, value) => value.includes('J'));
console.log(results); // [['name', 'Luppux']]
// MySQL bağlantısı kapatma
db.closeConnection();
// İndeksleme
db.createIndex('name');
const indexValues = db.getIndexValues();
console.log(indexValues); // ['Luppux']
// Transaksiyonlar
db.startTransaction();
db.set('name', 'Luppux');
db.set('age', 35);
db.commitTransaction();
console.log(db.read('name')); // Jane Smith
console.log(db.read('age')); // 35
// Veritabanı yedekleme ve geri yükleme
db.backup('backup.json');
db.restore('backup.json');
console.log(db.read('name')); // Luppux
// Diğer işlemler
db.createCollection('users'); // Yeni bir koleksiyon oluşturur
db.insert('users', { name: 'Alice', age: 30 }); // Koleksiyona yeni bir belge ekler
db.find('users', { age: { $gt: 25 } }); // Belirli bir koşula göre belgeleri bulur
db.updateOne('users', { name: 'Alice' }, { $set: { age: 31 } }); // Belirli bir belgeyi günceller
db.deleteOne('users', { name: 'Alice' }); // Belirli bir belgeyi siler
db.aggregate('users', [{ $group: { _id: '$age', count: { $sum: 1 } } }]); // Agregasyon işlemi yapar
// ...
npm install twilight.db
veya
yarn add twilight.db
Daha fazla bilgi için GitHub sayfamızı !ziyaret edebilirsiniz.
FAQs
Créated By Weatrix
The npm package twilight.db receives a total of 0 weekly downloads. As such, twilight.db popularity was classified as not popular.
We found that twilight.db demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer 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
/Research
A fake corepack.org site is impersonating the Node.js tool and delivers an infostealer and proxyware to developers who download it.

Research
/Security News
A large-scale campaign abused GitHub Actions in compromised repositories to exploit CVE-2026-41940 in cPanel and WHM and steal server credentials.

Security News
Five frontier LLMs generated the same nonexistent package names, leaving 53 available for potential slopsquatting across PyPI and npm.