Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

kysely-kit

Package Overview
Dependencies
Maintainers
1
Versions
29
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

kysely-kit - npm Package Compare versions

Comparing version 0.4.1 to 0.4.2

6

build/cli/commands/generate-types/generate-table-types.js

@@ -11,3 +11,4 @@ import camelcase from 'camelcase';

const name = camelcase(column.name);
let type = mapDataType(column.dataType);
const isArray = column.dataType.startsWith('_');
let type = mapDataType(isArray ? column.dataType.slice(1) : column.dataType);
if (name === 'createdAt' && type === 'Date' && column.hasDefaultValue) {

@@ -20,2 +21,5 @@ type = 'GeneratedAlways<Date>';

else {
if (isArray) {
type = `${type}[]`;
}
if (column.isAutoIncrementing) {

@@ -22,0 +26,0 @@ type = `GeneratedAlways<${type}>`;

@@ -7,2 +7,3 @@ export default function mapDataType(dataType) {

return 'JSONColumnType<{}>';
case 'text':
case 'varchar':

@@ -9,0 +10,0 @@ return 'string';

2

package.json
{
"name": "kysely-kit",
"description": "Useful utilities for working with Kysely",
"version": "0.4.1",
"version": "0.4.2",
"author": "Vlad Shcherbin <vlad.shcherbin@gmail.com>",

@@ -6,0 +6,0 @@ "repository": "vladshcherbin/kysely-kit",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc