GithubHelp home page GithubHelp logo

neondatabase / website Goto Github PK

View Code? Open in Web Editor NEW
156.0 10.0 66.0 719.84 MB

Official docs and website for Neon.

Home Page: https://neon.tech

CSS 5.57% JavaScript 94.39% Shell 0.04%
design docs gatsby website

website's Introduction

Neon Next.js

Table of Contents

Getting Started

  1. Clone this repository
git clone [email protected]:neondatabase/website.git
  1. Install dependencies
npm install
  1. Fill environment variables
cp .env.example .env

Usage

Run the website

npm run dev

Open http://localhost:3000 with your browser to see the result.

You can start editing the page by modifying src/app/page.jsx. The page auto-updates as you edit the file.

Build the website

npm run build

Run the built website

npm run start

Checks broken links

npm run check:broken-links -- https://neon.tech

The command may take time, be patient. You can also specify which part of the website you want to check by passing a specific URL, for example https://neon.tech/docs for checking the Docs

N.B. The automatic check is done every Monday at midnight by GitHub CI. You can find the reports on the "Actions" tab

Learn More

To learn more about Next.js, take a look at the following resources:

You can check out the Next.js GitHub repository - your feedback and contributions are welcome!

Deploy on Vercel

The easiest way to deploy your Next.js app is to use the Vercel Platform from the creators of Next.js.

Check out our Next.js deployment documentation for more details.

Project Structure

├── content — Documentation sources in `mdbook` format, see [Documentation](#docs) section
├── public
├── src
│   ├── app
│   ├── components
│   │  ├── pages — React components that are being used specifically on a certain page
│   │  └── shared — React components that are being used across the whole website
│   ├── hooks
│   ├── icons
│   ├── images
│   ├── lib
│   ├── scripts
│   ├── styles
│   ├── utils
├── next.config.js — Main configuration file for a Next.js site. Read more about it [here](https://nextjs.org/docs/api-reference/next.config.js/introduction)
├── postcss.config.js — Main configuration file of PostCSS. [Read more about it here](https://tailwindcss.com/docs/configuration#generating-a-post-css-configuration-file)
└── tailwind.config.js — Main configuration file for Tailwind CSS [Read more about it here](https://tailwindcss.com/docs/configuration)

Component Folder Structure

Each component includes

  1. Main JavaScript File
  2. Index File

Each component optionally may include

  1. Folder with images and icons
  2. Folder with data

Also, each component may include another component that follows all above listed rules.

Example structure

component
├── nested-component
│  ├── data
│  │  └── nested-component-lottie-data.json
│  ├── images
│  │  ├── nested-component-image.jpg
│  │  ├── nested-component-inline-svg.inline.svg
│  │  └── nested-component-url-svg.url.svg
│  ├── nested-component.js
│  └── index.js
├── data
│  └── component-lottie-data.json
├── images
│  ├── component-image.jpg
│  ├── component-inline-svg.inline.svg
│  └── component-url-svg.url.svg
├── component.js
└── index.js

Code Style

ESLint

ESLint helps find and fix code style issues and force developers to follow same rules. Current configuration is based on Airbnb style guide.

Additional commands:

npm run lint

Run it to check the current status of eslint issues across project.

npm run lint:fix

Run it to fix all possible issues.

Prettier

Prettier helps to format code based on defined rules. Difference between Prettier and ESLint.

Additional commands:

npm run format

Run it to format all files across the project.

VS Code

Following extensions required to simplify the process of keeping the same code style across the project:

After installation enable "ESLint on save" by adding to your VS Code settings.json the following line:

"editor.codeActionsOnSave": {
    "source.fixAll.eslint": true
}

You can navigate to settings.json by using Command Pallete (CMD+Shift+P) and then type "Open settings.json".

To enable Prettier go to Preferences -> Settings -> type "Format". Then check that you have esbenp.prettier-vscode as default formatter, and also enable "Format On Save".

Reload VS Code and auto-format will work for you.

Docs

Documentation for docs is described in content/docs/README.md

website's People

Contributors

actions-user avatar alexandriastech avatar americano98 avatar ananis25 avatar andrewgolovanov avatar antonyc avatar bgrenon avatar bolotskydev avatar carlotas19 avatar danieltprice avatar den-bratchikov avatar evanshortiss avatar ikatemart avatar k8isdead avatar kelvich avatar lnikell avatar m-abdelwahab avatar nikitashamgunov avatar pauliescanlon avatar raoufchebri avatar ruf-io avatar saimonkat avatar sashasushko avatar silencerweb avatar stepashka avatar vannyle avatar vi-nastya avatar weaponxii avatar yasell avatar yirenlu92 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  avatar  avatar  avatar  avatar

website's Issues

Move project data size content

Move the information about checking the project data size out of the Technical Preview Free Tier topic. This content should be moved to a section about managing projects.

Docs: Improve SEO - Phase 1

This task is to outline specific steps that we can take to maximize SEO for our site, including the blog and docs, and to implement those steps. For instance, when someone is Googling how to connect to Postgresql, what can we do improve the odds of our content ranking high in search results?

The migration to Vercel will impact choices and options, but here are a few suggestions form the team for which there may be equivalents post-Gatsby:

  • Competitors use subtitles in their docs. Does this help and should we be doing the same?
  • Enable https://json-ld.org/ for our blog posts. See Google docs: Introduction to structured data markup in Google Search
  • Our html is not gzipped, however all other assets are gzipped. This may affect some performance metrics, and Google can decrease our SEO rank because of site speed. At this moment, our speed is good, but some tools have warned about this.

Apply for Algolia DocSearch

To further improve UX and especially DX for Neon users we suggest Neon to apply for Algolia DocSearch solution. It bears following benefits:

  • a dedicated, docs-tuned crawler
  • perf improvements
  • a modern up-to-date UI components out of the box with all best practices in place
  • fully customizable (brand guidelines can be applied)
  • 100% free

Neon is fully eligible for this one.

Mention that some psql clients may require SNI fiddling

I have some issues using the standard psql on Ubuntu 20.04 (postgresql-client APT package): https://github.com/neondatabase/cloud/issues/1405

Seems like the issue is fixed by using Ubuntu 22.04. As Ubuntu 20.04 is still supported, I think it may be worth mentioning at https://neon.tech/docs/get-started-with-neon/query-with-psql-editor . E.g. add the following text to both the "Connect with an exported password" and "Connect with a password saved to a file" sections:

Note that some older psql executables (e.g. from Ubuntu 20.04's postgresql-client package) are built without SNI support and require a workaround: https://neon.tech/docs/how-to-guides/connectivity-issues/#a-pass-project-id-in-options

Add CODEOWNERS file to website repo

Hi @bolotskydev, @lnikell,
cc @stepashka

Anna suggested adding a CODEOWNERS file to the website repository to ensure that PR reviewers are notified.
https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-code-owners

As an example, the cloud repo has this CODEOWNERS file:
https://github.com/neondatabase/cloud/blob/main/.github/CODEOWNERS

I will add myself as a code owner for the /docs so that I am automatically added as a reviewer for changes to files in that directory:

/content/docs/ @danieltprice

Could I ask you to identify (in this Issue) the directories or files for which you want to be defined as a code owner?

Once everyone has responded, we'll add the CODEOWNERS file.

Thank you!

Finding it hard to read node.js connection documentation

By default there is no branching available to users. So, someone who wants to try with the bare bones into NeonDB will struggle to find things without branch. If default purpose is not allowing branching then the document should be done in the similar manner.

I was reading this page https://neon.tech/docs/guides/node/ and found no nothing about branching and was super confused with the variables and the url which I had.

Let's draft two sections separately or move this particular connection method under the branching topic here https://neon.tech/docs/introduction/branching/#branch-endpoints

Also, Now the options is no longer working as expected. It throws errors when used. But if we remove options then it works as expected.
So URL should be

postgres://${process.env.PGUSER}:${process.env.PGPASSWORD}@${process.env.ENDPOINT_ID}/${process.env.PGDATABASE}?sslmode=require

Update blog design

We've delivered update for Docs, Blog is next in queue 🤖

  • Dark theme
  • #381
  • #311
  • more visibility of the covers in the list
  • support for the second author
  • consider support for more author? this would affect the UI
  • categories? @raoufchebri to add here
  • align the target wordcount for the description 140-280 symbols (tweet size) @raoufchebri @m-abdelwahab to take this
  • 'star us on github' snippets for CTA & tracking
  • Make sure that code blocks have the correct line height and font size

Document Neon domains

pg.neon.tech (for link auth)
connect.neon.tech (also for link auth)
project_id.cloud.neon.tech (old but still supported domain)
endpoint_id.region_slug.platform.neon.tech (domain for SNI-enabled clients)

Mention the default Postgres schema in docs

PostgreSQL has not only databases and tables/relations, but also "schemas". Some people never encounter them and use the default schema called public, while some PostgreSQL clients (like Postgrest: neondatabase/neon#1938) require explicitly specifying the schema.

It'd be nice to mention the default schema name (public) somewhere in the documentation for generic connection settings, even though it's not Neon-related, strictly speaking.

Documentation is not searchable

Steps to reproduce

Search for site:neon.tech "Two PostgreSQL database users are created with each Neon project" with either of: google.com, duckduckgo.com, yandex.com

Expected result

All three engines return a link to https://neon.tech/docs/reference/glossary/#postgresql-user

Actual result

Only yandex.com finds the page, Google and DuckDuckGo find nothing:
image

image

image

Impact

Some questions are in the documentation, but are not the first thing the user meets, like the web-access PostgreSQL user (see https://github.com/neondatabase/cloud/issues/1403). If a user encounters them, it'd be nice for them to be able to look up the answer with a search engine instead of reading all pages on our website. Also, a global search engine is probably more powerful than anything we can roll out ourselves anyway.

Add documentation for Operations

Add documentation for Operations widget and log. The Operations widget appears on the Dashboard. We would like to link to this content from the Console to explain the different operations represented there.

Fix dead link /docs/api/about/

When you click on 'Neon API' in the onboarding section of the console, a dead link shows up.
image

I know it's all not publicly available yet, but I thought it might still help.

Address linter issues

It seems that some of the docs content breaks the linter rules. Please, adjust as you see fit

screenshot of the report

Image

add tracking for all the buttons in GA

I think it makes sense to agree on exact list of buttons we are going to track prior to tracking implementation. Otherwise all the buttons sounds pretty vague.

Address Algolia issues

  1. Clicks in Algolia search results are not being tracked properly
  2. Algolia search results include doc files not included in the TOC. Indices need to be rebuilt, but how do we exclude files from being indexed again?
  3. Where can we place draft files so that they do not show up in search results? Can we exclude files or folders in the content directory from being indexed?

Document branching

@stepashka @klink @seymourisdead
Topics to be created:

Get started

  • Branching

Branching

  • About branching
  • Creating a branch
  • Viewing branches
  • Deleting a branch
  • Using the Neon API
  • Branching workflows

Description of topics:

Branch quickstart

This will be a quickstart for branching, with screen captures, that introduced users to the basics of creating and connecting to a branch. Think of it as an introductory tutorial.

Branching

This is the core branching documentation (concept and task). It will provide an introduction to branching, how to create, view, and delete branches, branching using the Neon API, and branching workflows.

Mention that DataGrip/CLion/other JetBrains tools do not support `user:password` in connection strings by default

See https://github.com/neondatabase/cloud/issues/1619 for the context. The default PostgreSQL driver for DataGrip does not support our connection strings of form postgres://user:password@host, it cannot extract user/password from the connection string at all.

I'd add the following comment to DataGrip's row in https://neon.tech/docs/how-to-guides/connectivity-issues/#applications 👍

User and password are not parsed from the connection string and should be provided separately

create visual guidelines for the docs

Define Neon screen capture, image, and diagram styles & process:

Consider the following resources:
- https://docs.google.com/presentation/d/16BUe_P3Cz7dzJkjBr8AtV7ETstZDOvYPF0tiEEEycHs/edit#slide=id.g1332016fb25_1_1
- https://docs.google.com/presentation/d/1S7jCMvHXIRMelfZxin6q3-091IGEfcLvogDfbhsqCK4/edit#slide=id.g13beed2dab8_1_0
- https://mermaid-js.github.io/mermaid/#/
- https://github.com/neondatabase/cloud/tree/main/docs/sequencediagrams

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.