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

easy-mysql-js

Package Overview
Dependencies
Maintainers
0
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

easy-mysql-js - npm Package Compare versions

Comparing version 1.0.1 to 1.0.2

13

index.js

@@ -15,4 +15,15 @@ /*

const { Prisma } = require('@prisma/client')
const prisma = require("./prisma/prisma.js")
const { PrismaClient } = require('@prisma/client')
let prisma;
if (process.env.NODE_ENV === 'production') {
prisma = new PrismaClient();
} else {
if (!global.prisma) {
global.prisma = new PrismaClient();
}
prisma = global.prisma;
}
// --------------------------------------------------------------------------------------------------

@@ -19,0 +30,0 @@ // Select -------------------------------------------------------------------------------------------

2

package.json
{
"name": "easy-mysql-js",
"version": "1.0.1",
"version": "1.0.2",
"description": "Easy MySQL for NodeJS",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -17,6 +17,21 @@ # easy-mysql-js

Install the package
```shell
$ npm i easy-mysql-js
```
Initialize prisma
```shell
$ npx prisma init
```
NOTE: If you update your database tables, columns, etc. you need to run:
```shell
$ npx prisma db pull
$ npx prisma generate
```
## Environment Variables

@@ -26,5 +41,5 @@

`DATABASE_URL`
`DATABASE_URL="mysql://your_db_username:your_db_password@your_ip_address:3306/your_db_name"`
`NODE_ENV`
`NODE_ENV="development"`

@@ -34,4 +49,4 @@

***
## Select

@@ -38,0 +53,0 @@

Sorry, the diff of this file is not supported yet

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