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 🙏

© 2024 – Pkg Stats / Ryan Hefner

lift-prototype

v0.0.10

Published

- Declarative data modelling syntax - Supports relational and document databases (more coming soon) - Keeps a migration history - Before- and after hooks to run scripts for complex migrations - Simple defaults, optional complexity for advanced use cases -

Downloads

19

Readme

Lift is a powerful database schema migration tool. It uses a declarative data modelling syntax to describe your database schema. Lift stores your entire migration history and easily lets you revert and replay migrations. When migrating your database with Lift, you can run provide before- and after-hooks to execute scripts, e.g. to populate the database with required values during a migration.

It is part of the Prisma ecosystem. Prisma provides a family of tools to simplify database workflows for data access, declarative data modeling, schema migrations and visual data management. Learn more.

Features

  • Declarative data modelling syntax
  • Supports relational and document databases (more coming soon)
  • Keeps a migration history
  • Before- and after hooks to run scripts for complex migrations
  • Simple defaults, optional complexity for advanced use cases
  • Revert and replay migrations
  • Works with existing databases using schema introspection
  • CLI to support all major workflows

How it works

1. Configure database access

Specify the connection details for your database:

  • host: The IP address or domain name of the machine where your database server is running.
  • port: The port on which your database server is listening.
  • user & password: Credentials for your database sever.

2. Introspect your database

Introspect your database schema using the Prisma CLI to generate your datamodel. The datamodel is a declarative and human-readable representation of your database schema.

3. Adjust the datamodel

Instead of sending SQL migration statements to the database, you need to adjust the datamodel file to describe your desired database schema. You can express any schema migration you like using the new datamodel, this includes for example adding a new model, removing a model or updating the fields of a model. You can also add indexes or validation constraints in the datamodel.

You can create a new migration for your change by running prisma lift create and giving your migration a <name>.

$ prisma lift create "add comment model"

Created a new migration in "./lift/add-comment-model"

4. Migrate your database (apply datamodel changes)

Once you're happy with the changes, you can use the Prisma CLI to migrate your database (i.e. map the adjusted datamodel to your database). Lift's migration engine will generate the corresponding SQL statements and send them to the database for you.

$ prisma lift up

+ model Comment {
+   comment    String
+   author     User
+   createdAt  Datetime
+   updatedAt  Datetime
+ }
+

🚀 Ready to lift off? [y/N]

Supported databases

Photon JS can be used with the following databases:

  • MySQL
  • PostgreSQL
  • MongoDB (coming very soon)

More databases that will be supported in the future are:

  • MS SQL
  • Oracle
  • Neo4J
  • FaunaDB
  • ...