Giter Club home page Giter Club logo

supabase-schema's Introduction


Logo

Supabase Schema

Secured & Simple Supabase Schema Visualizer.
No installations • No Database password required.

View Demo · Report Bug · Request Feature

Supabase Schema

🚀 Features

  • 🔨 No installations
  • 🔒 Persistent State in LocalStorage
  • 🚪 Login-less
  • 👀 No Sensitive info required
  • 🤚 Moveable Schema for own design

📇 About The Project

I look around the internet and found many Database Schema Visualizers that require me to either download the software, or login to view my Database Schema. I feel like there's too many unneccessary steps, just to view the schema.

Thus, I've decided to take this opportunity to build this Open Source, Free, Login-less and Secured Supabase Schema Visualizer 🔥

🔨 Built With

🐾 Instructions

  1. Go to Supabase App
  2. Select your Project
  3. Go to Settings
  4. In Settings tab, Go to API
  5. Under Config, copy URL
  6. Under API Keys, copy anon public
  7. Paste both value into their respectively slot in Supabase Schema
  8. Fetch data
  9. Enjoy the Visualization 🎉

Remeber to ⭐ this repo if you ❤ this Apps

🌎 Local Development

Prerequisites

Yarn

  • npm install --global yarn

Development

  1. Clone the repo
    git clone https://github.com/zernonia/supabase-schema.git
  2. Install NPM packages
    yarn install
  3. Run Development instance
    yarn dev

➕ Contributing

Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are greatly appreciated.

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

🙏 Acknowledgement

  1. Fundamental for this Visualization (Generate database types from OpenAPI specification)
  2. Guide to Construct Dynamic SVG Connector (Connecting Table using SVG)
  3. Icones - icon gallery

📈 Analytics

I'm using Umami Analytics because I'm interested in the distributions of user who uses Supabase and this tool.

This is the public URL for the analytics. Enjoy!

📜 License

Not Associated with Supabase.

Distributed under the MIT License. See LICENSE for more information.

📧 Contact

Zernonia - @zernonia - [email protected]

Also, if you like my work, please buy me a coffee ☕😳

Logo

supabase-schema's People

Contributors

tille0110 avatar zernonia avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

supabase-schema's Issues

Feature request: "Copy Prompt" button

Hello! First of all, this is a fantastic project. Thanks for making it, and for making is open source 😄

I have a feature request that I'd like your opinion on. I can open the PR and do the work, I just want to make sure you're on board for it. Currently to use the AI feature, you add a schema and query to a prompt and do the openAI (generously) call yourself. I like that all my tables are already injected into the prompt.

Let's say I have chatGPT premium, I want to paste the prompt into it and maybe carry on the conversation on in chatGPT.
So it'd be nice if there was a button to copy the prompt, already formatted with my table schemas, to paste into chatGPT.

Currently it's still possible of course, just inspect the request in the network tab and reformat it. This is just a little feature.

Views shown as Tables

Hi, Firstly it is great job! we needed it too much!

The issue is I have tables and views from tables but when I wanna export SQL views shown as tables.

Array column type

When you do an export of a table schema and one of the columns is of type text array, the array type is lost and it is left as simply array

When using the script, we receive a syntax error with the word ARRAY

Example:

image

create table candidates ( id uuid default uuid_generate_v4() primary key, created_at timestamp default now(), name text, email text, phone text, entry text, tag text, status text, quizzes json, file text, "level" text, profilesJobs ARRAY, notes ARRAY );

Sort types & export by default

When exporting types, it would be nice to make sure they are alpha-sorted so the diff between 2 versions are more readable.
Also, wouldn't it be better to export them all by default?

get url and anon key from query params

Hey, thanks for the tool!

We would like to use this for our internal documentation, and it would be awesome if our developers won't have to type in the url and anon key every time. Would it be possible to add these to the query params?

Best
Philipp

Support For Multiple Schemas

Hi, I have a project that uses numerous schemas (other than just public) and believe that there should be support for schemas that aren't named 'public'.

Light theme for the screenshot

Thanks for this really cool app! :)

While I like a lot the default dark theme, I think it would be cool to be able to switch to a light theme, at least for taking the screenshot of the diagram to make it printable.

Thanks!

unable to Pan using Touchpad (on laptop)

In abscense of a mouse, it is not possible to pan in the app's canvas using the laptop's touchpad.

I am using an HP laptop (Winx64). Possible solution: Spacebar+LeftClick or Shift+LeftClick.

Support for column description

It would be nice to also display the description of the columns in the visualization. It could be a tooltip after hover.

Generate schema fields with double quotes

Description

In one of my projects that used supabase-schema to generate the SQL scripts, many of fields use camelcase, hence the generated script by default does not work since Postgres require camelcase/uppercase fields to be included in double quotes. e.g. sourceRepo needs to be "sourceRepo"

Example Screenshot

Current fields that are generated

image

Running the above script will create the fields all in small caps, and all the calls to supabase DB from app will fail due to wrong schema.

Suggested solution

Hence, this issue is requesting for the generated script to include quotes.
P.S. I can also work on this if u can include hacktoberfest label to this 😄

User Defined types are not exported

create table questions_new_free_assessment (
  id bigint not null primary key,
  inserted_at timestamp default now() not null,
  updated_at timestamp default now() not null,
  question_text text not null,
  question_description text,
  **type public.valid_question_type not null,**
  choices text[],
  answer text,
  priority integer
);

Here the the column type is defined as a custom struct type of the valid_question_type but its not exported in the sql or ts

Schema Maker

Can you please make a schema maker where we just the diagram and your website automatically generates the database for us. Isn't it possible.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.