Compare commits
40 Commits
@nhost/rea
...
@nhost/rea
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
35068d213f | ||
|
|
e732ea9aa5 | ||
|
|
e8d5338aca | ||
|
|
ac84f4d0e9 | ||
|
|
12e9a572db | ||
|
|
23a9f9f547 | ||
|
|
1b37b9f62a | ||
|
|
764ea72d60 | ||
|
|
3efbbca136 | ||
|
|
93d8eec950 | ||
|
|
d4ea2fce6d | ||
|
|
5096456f78 | ||
|
|
507d09861c | ||
|
|
050cb288fc | ||
|
|
cd120c61fb | ||
|
|
5ddb5a751b | ||
|
|
92209b6690 | ||
|
|
bdb11c0fa4 | ||
|
|
63c3e7cb2c | ||
|
|
78341491cd | ||
|
|
cd8560e6d3 | ||
|
|
fced43f55d | ||
|
|
47cc5d1562 | ||
|
|
9ab4d49421 | ||
|
|
4bdd29c2ea | ||
|
|
a43fa284b4 | ||
|
|
e68ca9b0c8 | ||
|
|
ad26b8392f | ||
|
|
09ffcb961a | ||
|
|
42879a26da | ||
|
|
cdba9aa5a0 | ||
|
|
b092e13ba0 | ||
|
|
a2343c8ef2 | ||
|
|
2cbe8a5045 | ||
|
|
a38ddeed5e | ||
|
|
1fbf990c79 | ||
|
|
c5a9fc568b | ||
|
|
0b79b4f492 | ||
|
|
832702ff45 | ||
|
|
1791452fc2 |
39
README.md
@@ -1,4 +1,4 @@
|
|||||||

|

|
||||||
|
|
||||||
<div align="center">
|
<div align="center">
|
||||||
|
|
||||||
@@ -199,21 +199,28 @@ Here are some ways of contributing to making Nhost better:
|
|||||||
<sub><b>Vadim Smirnov</b></sub>
|
<sub><b>Vadim Smirnov</b></sub>
|
||||||
</a>
|
</a>
|
||||||
</td>
|
</td>
|
||||||
|
<td align="center">
|
||||||
|
<a href="https://github.com/macmac49">
|
||||||
|
<img src="https://avatars.githubusercontent.com/u/831190?v=4" width="100;" alt="macmac49"/>
|
||||||
|
<br />
|
||||||
|
<sub><b>Macmac49</b></sub>
|
||||||
|
</a>
|
||||||
|
</td>
|
||||||
<td align="center">
|
<td align="center">
|
||||||
<a href="https://github.com/subhendukundu">
|
<a href="https://github.com/subhendukundu">
|
||||||
<img src="https://avatars.githubusercontent.com/u/20059141?v=4" width="100;" alt="subhendukundu"/>
|
<img src="https://avatars.githubusercontent.com/u/20059141?v=4" width="100;" alt="subhendukundu"/>
|
||||||
<br />
|
<br />
|
||||||
<sub><b>Subhendu Kundu</b></sub>
|
<sub><b>Subhendu Kundu</b></sub>
|
||||||
</a>
|
</a>
|
||||||
</td>
|
</td></tr>
|
||||||
|
<tr>
|
||||||
<td align="center">
|
<td align="center">
|
||||||
<a href="https://github.com/heygambo">
|
<a href="https://github.com/heygambo">
|
||||||
<img src="https://avatars.githubusercontent.com/u/449438?v=4" width="100;" alt="heygambo"/>
|
<img src="https://avatars.githubusercontent.com/u/449438?v=4" width="100;" alt="heygambo"/>
|
||||||
<br />
|
<br />
|
||||||
<sub><b>Christian Gambardella</b></sub>
|
<sub><b>Christian Gambardella</b></sub>
|
||||||
</a>
|
</a>
|
||||||
</td></tr>
|
</td>
|
||||||
<tr>
|
|
||||||
<td align="center">
|
<td align="center">
|
||||||
<a href="https://github.com/chrtze">
|
<a href="https://github.com/chrtze">
|
||||||
<img src="https://avatars.githubusercontent.com/u/3797215?v=4" width="100;" alt="chrtze"/>
|
<img src="https://avatars.githubusercontent.com/u/3797215?v=4" width="100;" alt="chrtze"/>
|
||||||
@@ -248,15 +255,15 @@ Here are some ways of contributing to making Nhost better:
|
|||||||
<br />
|
<br />
|
||||||
<sub><b>Jerry Jäppinen</b></sub>
|
<sub><b>Jerry Jäppinen</b></sub>
|
||||||
</a>
|
</a>
|
||||||
</td>
|
</td></tr>
|
||||||
|
<tr>
|
||||||
<td align="center">
|
<td align="center">
|
||||||
<a href="https://github.com/mustafa-hanif">
|
<a href="https://github.com/mustafa-hanif">
|
||||||
<img src="https://avatars.githubusercontent.com/u/30019262?v=4" width="100;" alt="mustafa-hanif"/>
|
<img src="https://avatars.githubusercontent.com/u/30019262?v=4" width="100;" alt="mustafa-hanif"/>
|
||||||
<br />
|
<br />
|
||||||
<sub><b>Mustafa Hanif</b></sub>
|
<sub><b>Mustafa Hanif</b></sub>
|
||||||
</a>
|
</a>
|
||||||
</td></tr>
|
</td>
|
||||||
<tr>
|
|
||||||
<td align="center">
|
<td align="center">
|
||||||
<a href="https://github.com/timpratim">
|
<a href="https://github.com/timpratim">
|
||||||
<img src="https://avatars.githubusercontent.com/u/32492961?v=4" width="100;" alt="timpratim"/>
|
<img src="https://avatars.githubusercontent.com/u/32492961?v=4" width="100;" alt="timpratim"/>
|
||||||
@@ -291,15 +298,15 @@ Here are some ways of contributing to making Nhost better:
|
|||||||
<br />
|
<br />
|
||||||
<sub><b>Animesh Pathak</b></sub>
|
<sub><b>Animesh Pathak</b></sub>
|
||||||
</a>
|
</a>
|
||||||
</td>
|
</td></tr>
|
||||||
|
<tr>
|
||||||
<td align="center">
|
<td align="center">
|
||||||
<a href="https://github.com/rustyb">
|
<a href="https://github.com/rustyb">
|
||||||
<img src="https://avatars.githubusercontent.com/u/53086?v=4" width="100;" alt="rustyb"/>
|
<img src="https://avatars.githubusercontent.com/u/53086?v=4" width="100;" alt="rustyb"/>
|
||||||
<br />
|
<br />
|
||||||
<sub><b>Colin Broderick</b></sub>
|
<sub><b>Colin Broderick</b></sub>
|
||||||
</a>
|
</a>
|
||||||
</td></tr>
|
</td>
|
||||||
<tr>
|
|
||||||
<td align="center">
|
<td align="center">
|
||||||
<a href="https://github.com/dohomi">
|
<a href="https://github.com/dohomi">
|
||||||
<img src="https://avatars.githubusercontent.com/u/489221?v=4" width="100;" alt="dohomi"/>
|
<img src="https://avatars.githubusercontent.com/u/489221?v=4" width="100;" alt="dohomi"/>
|
||||||
@@ -334,15 +341,15 @@ Here are some ways of contributing to making Nhost better:
|
|||||||
<br />
|
<br />
|
||||||
<sub><b>Hugh Caluscusin</b></sub>
|
<sub><b>Hugh Caluscusin</b></sub>
|
||||||
</a>
|
</a>
|
||||||
</td>
|
</td></tr>
|
||||||
|
<tr>
|
||||||
<td align="center">
|
<td align="center">
|
||||||
<a href="https://github.com/jladuval">
|
<a href="https://github.com/jladuval">
|
||||||
<img src="https://avatars.githubusercontent.com/u/1935359?v=4" width="100;" alt="jladuval"/>
|
<img src="https://avatars.githubusercontent.com/u/1935359?v=4" width="100;" alt="jladuval"/>
|
||||||
<br />
|
<br />
|
||||||
<sub><b>Jacob Duval</b></sub>
|
<sub><b>Jacob Duval</b></sub>
|
||||||
</a>
|
</a>
|
||||||
</td></tr>
|
</td>
|
||||||
<tr>
|
|
||||||
<td align="center">
|
<td align="center">
|
||||||
<a href="https://github.com/leothorp">
|
<a href="https://github.com/leothorp">
|
||||||
<img src="https://avatars.githubusercontent.com/u/12928449?v=4" width="100;" alt="leothorp"/>
|
<img src="https://avatars.githubusercontent.com/u/12928449?v=4" width="100;" alt="leothorp"/>
|
||||||
@@ -377,15 +384,15 @@ Here are some ways of contributing to making Nhost better:
|
|||||||
<br />
|
<br />
|
||||||
<sub><b>Quentin Decré</b></sub>
|
<sub><b>Quentin Decré</b></sub>
|
||||||
</a>
|
</a>
|
||||||
</td>
|
</td></tr>
|
||||||
|
<tr>
|
||||||
<td align="center">
|
<td align="center">
|
||||||
<a href="https://github.com/atapas">
|
<a href="https://github.com/atapas">
|
||||||
<img src="https://avatars.githubusercontent.com/u/3633137?v=4" width="100;" alt="atapas"/>
|
<img src="https://avatars.githubusercontent.com/u/3633137?v=4" width="100;" alt="atapas"/>
|
||||||
<br />
|
<br />
|
||||||
<sub><b>Tapas Adhikary</b></sub>
|
<sub><b>Tapas Adhikary</b></sub>
|
||||||
</a>
|
</a>
|
||||||
</td></tr>
|
</td>
|
||||||
<tr>
|
|
||||||
<td align="center">
|
<td align="center">
|
||||||
<a href="https://github.com/komninoschat">
|
<a href="https://github.com/komninoschat">
|
||||||
<img src="https://avatars.githubusercontent.com/u/29049104?v=4" width="100;" alt="komninoschat"/>
|
<img src="https://avatars.githubusercontent.com/u/29049104?v=4" width="100;" alt="komninoschat"/>
|
||||||
|
|||||||
@@ -59,6 +59,7 @@ module.exports = {
|
|||||||
allowArrowFunction: true,
|
allowArrowFunction: true,
|
||||||
allowAnonymousFunction: true
|
allowAnonymousFunction: true
|
||||||
}
|
}
|
||||||
]
|
],
|
||||||
|
'import/extensions': ['error', { js: 'always' }]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
const base = require('./.eslint.base')
|
const base = require('./.eslint.base.js')
|
||||||
module.exports = {
|
module.exports = {
|
||||||
...base,
|
...base,
|
||||||
extends: ['react-app', 'plugin:react/recommended', 'plugin:react-hooks/recommended'],
|
extends: ['react-app', 'plugin:react/recommended', 'plugin:react-hooks/recommended'],
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
const base = require('./.eslint.base')
|
const base = require('./.eslint.base.js')
|
||||||
module.exports = {
|
module.exports = {
|
||||||
...base,
|
...base,
|
||||||
extends: ['plugin:import/recommended', 'plugin:import/typescript'],
|
extends: ['plugin:import/recommended', 'plugin:import/typescript'],
|
||||||
@@ -6,5 +6,8 @@ module.exports = {
|
|||||||
parserOptions: {
|
parserOptions: {
|
||||||
...base.parserOptions,
|
...base.parserOptions,
|
||||||
parser: '@typescript-eslint/parser'
|
parser: '@typescript-eslint/parser'
|
||||||
|
},
|
||||||
|
rules: {
|
||||||
|
'vue/html-self-closing': 'off'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -13,10 +13,24 @@ const entry = fs.existsSync(tsEntry) ? tsEntry : tsEntry.replace('.ts', '.tsx')
|
|||||||
|
|
||||||
const deps = [...Object.keys(Object.assign({}, pkg.peerDependencies, pkg.dependencies))]
|
const deps = [...Object.keys(Object.assign({}, pkg.peerDependencies, pkg.dependencies))]
|
||||||
|
|
||||||
|
function createModuleJsAndMapAfterBuild() {
|
||||||
|
return {
|
||||||
|
closeBundle() {
|
||||||
|
if (
|
||||||
|
fs.existsSync(path.join(PWD, 'dist/index.esm.js')) &&
|
||||||
|
fs.existsSync(path.join(PWD, 'dist/index.esm.js.map'))
|
||||||
|
) {
|
||||||
|
fs.copyFileSync(path.join(PWD, 'dist/index.esm.js'), path.join(PWD, 'dist/index.esm.mjs'))
|
||||||
|
fs.copyFileSync(
|
||||||
|
path.join(PWD, 'dist/index.esm.js.map'),
|
||||||
|
path.join(PWD, 'dist/index.esm.mjs.map')
|
||||||
|
)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
export default defineConfig({
|
export default defineConfig({
|
||||||
optimizeDeps: {
|
|
||||||
include: ['react/jsx-runtime']
|
|
||||||
},
|
|
||||||
plugins: [
|
plugins: [
|
||||||
tsconfigPaths(),
|
tsconfigPaths(),
|
||||||
dts({
|
dts({
|
||||||
@@ -28,7 +42,8 @@ export default defineConfig({
|
|||||||
})
|
})
|
||||||
fs.rmdirSync(path.join(PWD, 'dist/src'))
|
fs.rmdirSync(path.join(PWD, 'dist/src'))
|
||||||
}
|
}
|
||||||
})
|
}),
|
||||||
|
createModuleJsAndMapAfterBuild()
|
||||||
],
|
],
|
||||||
test: {
|
test: {
|
||||||
globals: true,
|
globals: true,
|
||||||
@@ -44,7 +59,7 @@ export default defineConfig({
|
|||||||
lib: {
|
lib: {
|
||||||
entry,
|
entry,
|
||||||
name: pkg.name,
|
name: pkg.name,
|
||||||
fileName: (format) => (format === 'cjs' ? `index.cjs.js` : `index.mjs`),
|
fileName: (format) => (format === 'cjs' ? `index.cjs.js` : `index.esm.js`),
|
||||||
formats: ['cjs', 'es']
|
formats: ['cjs', 'es']
|
||||||
},
|
},
|
||||||
rollupOptions: {
|
rollupOptions: {
|
||||||
@@ -53,10 +68,10 @@ export default defineConfig({
|
|||||||
globals: {
|
globals: {
|
||||||
graphql: 'graphql',
|
graphql: 'graphql',
|
||||||
'@apollo/client': '@apollo/client',
|
'@apollo/client': '@apollo/client',
|
||||||
'@apollo/client/core': '@apollo/client/core',
|
'@apollo/client/core/index.js': '@apollo/client/core',
|
||||||
'@apollo/client/link/context': '@apollo/client/link/context',
|
'@apollo/client/link/context/index.js': '@apollo/client/link/context',
|
||||||
'@apollo/client/link/subscriptions': '@apollo/client/link/subscriptions',
|
'@apollo/client/link/subscriptions/index.js': '@apollo/client/link/subscriptions',
|
||||||
'@apollo/client/utilities': '@apollo/client/utilities',
|
'@apollo/client/utilities/index.js': '@apollo/client/utilities',
|
||||||
'graphql-ws': 'graphql-ws',
|
'graphql-ws': 'graphql-ws',
|
||||||
xstate: 'xstate',
|
xstate: 'xstate',
|
||||||
axios: 'axios',
|
axios: 'axios',
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import { defineConfig } from 'vite'
|
import { defineConfig } from 'vite'
|
||||||
|
|
||||||
import viteLibConfig from './vite.lib.config'
|
import viteLibConfig from './vite.lib.config.js'
|
||||||
|
|
||||||
export default defineConfig({
|
export default defineConfig({
|
||||||
...viteLibConfig,
|
...viteLibConfig,
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ import path from 'path'
|
|||||||
import { defineConfig } from 'vite'
|
import { defineConfig } from 'vite'
|
||||||
import tsconfigPaths from 'vite-tsconfig-paths'
|
import tsconfigPaths from 'vite-tsconfig-paths'
|
||||||
|
|
||||||
import baseLibConfig from './vite.lib.config'
|
import baseLibConfig from './vite.lib.config.js'
|
||||||
|
|
||||||
const PWD = process.env.PWD
|
const PWD = process.env.PWD
|
||||||
const pkg = require(path.join(PWD, 'package.json'))
|
const pkg = require(path.join(PWD, 'package.json'))
|
||||||
|
|||||||
@@ -2,9 +2,12 @@ import { defineConfig } from 'vite'
|
|||||||
|
|
||||||
import react from '@vitejs/plugin-react'
|
import react from '@vitejs/plugin-react'
|
||||||
|
|
||||||
import baseLibConfig from './vite.lib.config'
|
import baseLibConfig from './vite.lib.config.js'
|
||||||
|
|
||||||
export default defineConfig({
|
export default defineConfig({
|
||||||
...baseLibConfig,
|
...baseLibConfig,
|
||||||
plugins: [react(), ...baseLibConfig.plugins]
|
optimizeDeps: {
|
||||||
|
include: ['react/jsx-runtime']
|
||||||
|
},
|
||||||
|
plugins: [react({ jsxRuntime: 'classic' }), ...baseLibConfig.plugins]
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import { defineConfig } from 'vite'
|
import { defineConfig } from 'vite'
|
||||||
|
|
||||||
import viteReactConfig from './vite.react.config'
|
import viteReactConfig from './vite.react.config.js'
|
||||||
|
|
||||||
export default defineConfig({
|
export default defineConfig({
|
||||||
...viteReactConfig,
|
...viteReactConfig,
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ import tsconfigPaths from 'vite-tsconfig-paths'
|
|||||||
|
|
||||||
import react from '@vitejs/plugin-react'
|
import react from '@vitejs/plugin-react'
|
||||||
|
|
||||||
import baseLibConfig from './vite.lib.config'
|
import baseLibConfig from './vite.lib.config.js'
|
||||||
|
|
||||||
const PWD = process.env.PWD
|
const PWD = process.env.PWD
|
||||||
const pkg = require(path.join(PWD, 'package.json'))
|
const pkg = require(path.join(PWD, 'package.json'))
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ import { defineConfig } from 'vite'
|
|||||||
|
|
||||||
import vue from '@vitejs/plugin-vue'
|
import vue from '@vitejs/plugin-vue'
|
||||||
|
|
||||||
import baseLibConfig from './vite.lib.config'
|
import baseLibConfig from './vite.lib.config.js'
|
||||||
|
|
||||||
export default defineConfig({
|
export default defineConfig({
|
||||||
...baseLibConfig,
|
...baseLibConfig,
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import { defineConfig } from 'vite'
|
import { defineConfig } from 'vite'
|
||||||
|
|
||||||
import viteVueConfig from './vite.vue.config'
|
import viteVueConfig from './vite.vue.config.js'
|
||||||
|
|
||||||
export default defineConfig({
|
export default defineConfig({
|
||||||
...viteVueConfig,
|
...viteVueConfig,
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ import tsconfigPaths from 'vite-tsconfig-paths'
|
|||||||
|
|
||||||
import vue from '@vitejs/plugin-vue'
|
import vue from '@vitejs/plugin-vue'
|
||||||
|
|
||||||
import baseLibConfig from './vite.lib.config'
|
import baseLibConfig from './vite.lib.config.js'
|
||||||
|
|
||||||
const PWD = process.env.PWD
|
const PWD = process.env.PWD
|
||||||
const pkg = require(path.join(PWD, 'package.json'))
|
const pkg = require(path.join(PWD, 'package.json'))
|
||||||
|
|||||||
@@ -2,6 +2,7 @@
|
|||||||
title: 'Introduction to Nhost'
|
title: 'Introduction to Nhost'
|
||||||
sidebar_label: Introduction
|
sidebar_label: Introduction
|
||||||
sidebar_position: 1
|
sidebar_position: 1
|
||||||
|
image: /img/og/platform/introduction-to-nhost.png
|
||||||
---
|
---
|
||||||
|
|
||||||
Nhost is the open source GraphQL backend (Firebase Alternative) and a development platform. Nhost is doing for the backend, what [Netlify](https://netlify.com/) and [Vercel](https://vercel.com/) are doing for the frontend.
|
Nhost is the open source GraphQL backend (Firebase Alternative) and a development platform. Nhost is doing for the backend, what [Netlify](https://netlify.com/) and [Vercel](https://vercel.com/) are doing for the frontend.
|
||||||
|
|||||||
@@ -2,6 +2,7 @@
|
|||||||
title: Nhost Authentication
|
title: Nhost Authentication
|
||||||
sidebar_label: Authentication
|
sidebar_label: Authentication
|
||||||
sidebar_position: 1
|
sidebar_position: 1
|
||||||
|
image: /img/og/platform/authentication.png
|
||||||
---
|
---
|
||||||
|
|
||||||
Nhost Authentication is a ready-to-use authentication service that is integrated with the [GraphQL API](/platform/graphql) and its permission system from Hasura.
|
Nhost Authentication is a ready-to-use authentication service that is integrated with the [GraphQL API](/platform/graphql) and its permission system from Hasura.
|
||||||
|
|||||||
@@ -2,6 +2,7 @@
|
|||||||
title: Sign In with Email and Password
|
title: Sign In with Email and Password
|
||||||
sidebar_label: Email and Password
|
sidebar_label: Email and Password
|
||||||
slug: /platform/authentication/sign-in-with-email-and-password
|
slug: /platform/authentication/sign-in-with-email-and-password
|
||||||
|
image: /img/og/platform/sign-in-with-email-and-password.png
|
||||||
---
|
---
|
||||||
|
|
||||||
Follow this guide to sign in users with email and password.
|
Follow this guide to sign in users with email and password.
|
||||||
|
|||||||
@@ -2,6 +2,7 @@
|
|||||||
title: Sign In with Magic Link
|
title: Sign In with Magic Link
|
||||||
sidebar_label: Magic Link
|
sidebar_label: Magic Link
|
||||||
slug: /platform/authentication/sign-in-with-magic-link
|
slug: /platform/authentication/sign-in-with-magic-link
|
||||||
|
image: /img/og/platform/sign-in-with-magic-link.png
|
||||||
---
|
---
|
||||||
|
|
||||||
Follow this guide to sign in users with Magic Link, also called passwordless email.
|
Follow this guide to sign in users with Magic Link, also called passwordless email.
|
||||||
|
|||||||
@@ -2,6 +2,7 @@
|
|||||||
title: Sign In with Phone Number (SMS)
|
title: Sign In with Phone Number (SMS)
|
||||||
sidebar_label: Phone Number (SMS)
|
sidebar_label: Phone Number (SMS)
|
||||||
slug: /platform/authentication/sign-in-with-phone-number-sms
|
slug: /platform/authentication/sign-in-with-phone-number-sms
|
||||||
|
image: /img/og/platform/sign-in-with-phone-number-sms.png
|
||||||
---
|
---
|
||||||
|
|
||||||
Follow this guide to sign in users with a phone number (SMS).
|
Follow this guide to sign in users with a phone number (SMS).
|
||||||
|
|||||||
@@ -2,6 +2,7 @@
|
|||||||
title: Sign In with Google
|
title: Sign In with Google
|
||||||
sidebar_label: Google
|
sidebar_label: Google
|
||||||
slug: /platform/authentication/sign-in-with-google
|
slug: /platform/authentication/sign-in-with-google
|
||||||
|
image: /img/og/platform/sign-in-with-google.png
|
||||||
---
|
---
|
||||||
|
|
||||||
Follow this guide to sign in users with Google with your Nhost App.
|
Follow this guide to sign in users with Google with your Nhost App.
|
||||||
|
|||||||
@@ -2,6 +2,7 @@
|
|||||||
title: Sign In with Facebook
|
title: Sign In with Facebook
|
||||||
sidebar_label: Facebook
|
sidebar_label: Facebook
|
||||||
slug: /platform/authentication/sign-in-with-facebook
|
slug: /platform/authentication/sign-in-with-facebook
|
||||||
|
image: /img/og/platform/sign-in-with-facebook.png
|
||||||
---
|
---
|
||||||
|
|
||||||
Follow this guide to sign in users with Facebook with your Nhost App.
|
Follow this guide to sign in users with Facebook with your Nhost App.
|
||||||
|
|||||||
@@ -2,6 +2,7 @@
|
|||||||
title: Sign In with GitHub
|
title: Sign In with GitHub
|
||||||
sidebar_label: GitHub
|
sidebar_label: GitHub
|
||||||
slug: /platform/authentication/sign-in-with-github
|
slug: /platform/authentication/sign-in-with-github
|
||||||
|
image: /img/og/platform/sign-in-with-github.png
|
||||||
---
|
---
|
||||||
|
|
||||||
Follow this guide to sign in users with GitHub with your Nhost App.
|
Follow this guide to sign in users with GitHub with your Nhost App.
|
||||||
|
|||||||
@@ -2,6 +2,7 @@
|
|||||||
title: Sign In with LinkedIn
|
title: Sign In with LinkedIn
|
||||||
sidebar_label: LinkedIn
|
sidebar_label: LinkedIn
|
||||||
slug: /platform/authentication/sign-in-with-linkedin
|
slug: /platform/authentication/sign-in-with-linkedin
|
||||||
|
image: /img/og/platform/sign-in-with-linkedin.png
|
||||||
---
|
---
|
||||||
|
|
||||||
Follow this guide to sign in users with LinkedIn with your Nhost App.
|
Follow this guide to sign in users with LinkedIn with your Nhost App.
|
||||||
|
|||||||
@@ -2,6 +2,7 @@
|
|||||||
title: Sign In with Spotify
|
title: Sign In with Spotify
|
||||||
sidebar_label: Spotify
|
sidebar_label: Spotify
|
||||||
slug: /platform/authentication/sign-in-with-spotify
|
slug: /platform/authentication/sign-in-with-spotify
|
||||||
|
image: /img/og/platform/sign-in-with-spotify.png
|
||||||
---
|
---
|
||||||
|
|
||||||
Follow this guide to sign in users with Spotify with your Nhost App.
|
Follow this guide to sign in users with Spotify with your Nhost App.
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
---
|
---
|
||||||
title: 'Sign-In Methods'
|
title: 'Sign-In Methods'
|
||||||
slug: /platform/authentication/sign-in-methods
|
slug: /platform/authentication/sign-in-methods
|
||||||
|
image: /img/og/platform/sign-in-methods.png
|
||||||
---
|
---
|
||||||
|
|
||||||
Nhost Authentication support the following sign-in methods:
|
Nhost Authentication support the following sign-in methods:
|
||||||
|
|||||||
@@ -2,6 +2,7 @@
|
|||||||
title: Tokens
|
title: Tokens
|
||||||
sidebar_label: Tokens
|
sidebar_label: Tokens
|
||||||
sidebar_position: 10
|
sidebar_position: 10
|
||||||
|
image: /img/og/platform/tokens.png
|
||||||
---
|
---
|
||||||
|
|
||||||
Nhost Authentication makes use of two types of tokens:
|
Nhost Authentication makes use of two types of tokens:
|
||||||
|
|||||||
@@ -2,6 +2,7 @@
|
|||||||
title: Users
|
title: Users
|
||||||
sidebar_label: Users
|
sidebar_label: Users
|
||||||
sidebar_position: 1
|
sidebar_position: 1
|
||||||
|
image: /img/og/platform/users.png
|
||||||
---
|
---
|
||||||
|
|
||||||
Users are stored in the database in the `users` table in the `auth` schema.
|
Users are stored in the database in the `users` table in the `auth` schema.
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
---
|
---
|
||||||
title: 'CLI'
|
title: 'CLI'
|
||||||
sidebar_position: 11
|
sidebar_position: 11
|
||||||
|
image: /img/og/platform/cli.png
|
||||||
---
|
---
|
||||||
|
|
||||||
import Tabs from '@theme/Tabs'
|
import Tabs from '@theme/Tabs'
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
---
|
---
|
||||||
title: 'Event triggers'
|
title: 'Event triggers'
|
||||||
sidebar_position: 2
|
sidebar_position: 2
|
||||||
|
image: /img/og/platform/event-triggers.png
|
||||||
---
|
---
|
||||||
|
|
||||||
Event Triggers enable you to invoke webhooks when a database event happens. Event Triggers are typically used to do post-processing tasks, using custom backend code, based on database events.
|
Event Triggers enable you to invoke webhooks when a database event happens. Event Triggers are typically used to do post-processing tasks, using custom backend code, based on database events.
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
---
|
---
|
||||||
title: 'Database'
|
title: 'Database'
|
||||||
sidebar_position: 1
|
sidebar_position: 1
|
||||||
|
image: /img/og/platform/database.png
|
||||||
---
|
---
|
||||||
|
|
||||||
import Tabs from '@theme/Tabs'
|
import Tabs from '@theme/Tabs'
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
---
|
---
|
||||||
title: 'Environment Variables'
|
title: 'Environment Variables'
|
||||||
sidebar_position: 9
|
sidebar_position: 9
|
||||||
|
image: /img/og/platform/environment-variables.png
|
||||||
---
|
---
|
||||||
|
|
||||||
Environment Variables are key-value pairs configured outside your source code. They are used to store environment-specific values such as API keys.
|
Environment Variables are key-value pairs configured outside your source code. They are used to store environment-specific values such as API keys.
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
---
|
---
|
||||||
title: 'GitHub Integration'
|
title: 'GitHub Integration'
|
||||||
sidebar_position: 10
|
sidebar_position: 10
|
||||||
|
image: /img/og/platform/github-integration.png
|
||||||
---
|
---
|
||||||
|
|
||||||
The GitHub integration allows you to automatically deploy your Nhost app when on push and merge to a GitHub repository that is connected to your Nhost app.
|
The GitHub integration allows you to automatically deploy your Nhost app when on push and merge to a GitHub repository that is connected to your Nhost app.
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
---
|
---
|
||||||
title: 'GraphQL'
|
title: 'GraphQL'
|
||||||
sidebar_position: 1
|
sidebar_position: 1
|
||||||
|
image: /img/og/platform/graphql.png
|
||||||
---
|
---
|
||||||
|
|
||||||
A GraphQL API is automatically and instantly available based on the tables and columns in your [database](/platform/database).
|
A GraphQL API is automatically and instantly available based on the tables and columns in your [database](/platform/database).
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
---
|
---
|
||||||
title: 'Permissions'
|
title: 'Permissions'
|
||||||
sidebar_position: 1
|
sidebar_position: 1
|
||||||
|
image: /img/og/platform/permissions.png
|
||||||
---
|
---
|
||||||
|
|
||||||
The GraphQL API is protected by a role-based permission system.
|
The GraphQL API is protected by a role-based permission system.
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
---
|
---
|
||||||
title: 'Architecture'
|
title: 'Architecture'
|
||||||
sidebar_position: 2
|
sidebar_position: 2
|
||||||
|
image: /img/og/platform/architecture.png
|
||||||
---
|
---
|
||||||
|
|
||||||
Nhost is a backend as a service built with open source tools to provide developers the general building blocks required to build fantastic digital apps and products.
|
Nhost is a backend as a service built with open source tools to provide developers the general building blocks required to build fantastic digital apps and products.
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
---
|
---
|
||||||
title: 'Get Started with Nhost CLI'
|
title: 'Get Started with Nhost CLI'
|
||||||
sidebar_position: 2
|
sidebar_position: 2
|
||||||
|
image: /img/og/platform/get-started-with-nhost-cli.png
|
||||||
---
|
---
|
||||||
|
|
||||||
# Get started with Nhost CLI
|
# Get started with Nhost CLI
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
---
|
---
|
||||||
title: 'Quickstart: Next.js'
|
title: 'Quickstart: Next.js'
|
||||||
sidebar_position: 2
|
sidebar_position: 2
|
||||||
|
image: /img/og/platform/quickstart-nextjs.png
|
||||||
---
|
---
|
||||||
|
|
||||||
import Tabs from '@theme/Tabs'
|
import Tabs from '@theme/Tabs'
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
---
|
---
|
||||||
title: 'Quickstart: React'
|
title: 'Quickstart: React'
|
||||||
sidebar_position: 1
|
sidebar_position: 1
|
||||||
|
image: /img/og/platform/quickstart-react.png
|
||||||
---
|
---
|
||||||
|
|
||||||
import Tabs from '@theme/Tabs'
|
import Tabs from '@theme/Tabs'
|
||||||
@@ -35,6 +36,7 @@ You'll need **Node.js** version 14 or later: [install it from here](https://node
|
|||||||
import CreateApp from '@site/src/components/create-nhost-app.mdx'
|
import CreateApp from '@site/src/components/create-nhost-app.mdx'
|
||||||
|
|
||||||
<CreateApp />
|
<CreateApp />
|
||||||
|
|
||||||
:::info
|
:::info
|
||||||
You can also connect your Nhost app to a GitHub repository. When you do this, any updates you push to your code will automatically be deployed. [Learn more](https://docs.nhost.io/platform/github-integration).
|
You can also connect your Nhost app to a GitHub repository. When you do this, any updates you push to your code will automatically be deployed. [Learn more](https://docs.nhost.io/platform/github-integration).
|
||||||
:::
|
:::
|
||||||
@@ -636,7 +638,8 @@ const Layout = () => {
|
|||||||
const id = useUserId()
|
const id = useUserId()
|
||||||
// highlight-start
|
// highlight-start
|
||||||
const { loading, error, data } = useQuery(GET_USER_QUERY, {
|
const { loading, error, data } = useQuery(GET_USER_QUERY, {
|
||||||
variables: { id }
|
variables: { id },
|
||||||
|
skip: !id
|
||||||
})
|
})
|
||||||
const user = data?.user
|
const user = data?.user
|
||||||
// highlight-end
|
// highlight-end
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
---
|
---
|
||||||
title: 'Quickstart: RedwoodJS'
|
title: 'Quickstart: RedwoodJS'
|
||||||
sidebar_position: 3
|
sidebar_position: 3
|
||||||
|
image: /img/og/platform/quickstart-redwoodjs.png
|
||||||
---
|
---
|
||||||
|
|
||||||
import Tabs from '@theme/Tabs'
|
import Tabs from '@theme/Tabs'
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
---
|
---
|
||||||
title: 'Quickstart: Vue'
|
title: 'Quickstart: Vue'
|
||||||
sidebar_position: 3
|
sidebar_position: 3
|
||||||
|
image: /img/og/platform/quickstart-vue.png
|
||||||
---
|
---
|
||||||
|
|
||||||
import Tabs from '@theme/Tabs'
|
import Tabs from '@theme/Tabs'
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
---
|
---
|
||||||
title: 'Serverless Functions'
|
title: 'Serverless Functions'
|
||||||
sidebar_position: 8
|
sidebar_position: 8
|
||||||
|
image: /img/og/platform/serverless-functions.png
|
||||||
---
|
---
|
||||||
|
|
||||||
import Tabs from '@theme/Tabs'
|
import Tabs from '@theme/Tabs'
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
---
|
---
|
||||||
title: 'Storage'
|
title: 'Storage'
|
||||||
sidebar_position: 7
|
sidebar_position: 7
|
||||||
|
image: /img/og/platform/storage.png
|
||||||
---
|
---
|
||||||
|
|
||||||
Nhost stores and serves files of any type in your backend.
|
Nhost stores and serves files of any type in your backend.
|
||||||
|
|||||||
@@ -43,7 +43,6 @@ sidebar_position: 3
|
|||||||
| AUTH_SMS_TWILIO_ACCOUNT_SID | | |
|
| AUTH_SMS_TWILIO_ACCOUNT_SID | | |
|
||||||
| AUTH_SMS_TWILIO_AUTH_TOKEN | | |
|
| AUTH_SMS_TWILIO_AUTH_TOKEN | | |
|
||||||
| AUTH_SMS_TWILIO_MESSAGING_SERVICE_ID | | |
|
| AUTH_SMS_TWILIO_MESSAGING_SERVICE_ID | | |
|
||||||
| AUTH_SMS_TWILIO_FROM | | |
|
|
||||||
| AUTH_EMAIL_SIGNIN_EMAIL_VERIFIED_REQUIRED | When enabled, any email-based authentication requires emails to be verified by a link sent to this email. | `true` |
|
| AUTH_EMAIL_SIGNIN_EMAIL_VERIFIED_REQUIRED | When enabled, any email-based authentication requires emails to be verified by a link sent to this email. | `true` |
|
||||||
| AUTH_ACCESS_CONTROL_ALLOWED_REDIRECT_URLS | | |
|
| AUTH_ACCESS_CONTROL_ALLOWED_REDIRECT_URLS | | |
|
||||||
| AUTH_MFA_ENABLED | Enables users to use Multi Factor Authentication. | `false` |
|
| AUTH_MFA_ENABLED | Enables users to use Multi Factor Authentication. | `false` |
|
||||||
|
|||||||
@@ -1,12 +1,12 @@
|
|||||||
---
|
---
|
||||||
title: 'Overview'
|
title: 'JavaScript'
|
||||||
sidebar_position: 1
|
sidebar_position: 1
|
||||||
---
|
---
|
||||||
|
|
||||||
import Tabs from '@theme/Tabs'
|
import Tabs from '@theme/Tabs'
|
||||||
import TabItem from '@theme/TabItem'
|
import TabItem from '@theme/TabItem'
|
||||||
|
|
||||||
The Nhost client is the primary way of interacting with your Nhost app. It exposes a standard interface for each of the following services:
|
The Nhost JavaScript client is the primary way of interacting with your Nhost app. It exposes a standard interface for each of the following services:
|
||||||
|
|
||||||
- [Authentication](/reference/javascript/auth)
|
- [Authentication](/reference/javascript/auth)
|
||||||
- [Storage](/reference/javascript/storage)
|
- [Storage](/reference/javascript/storage)
|
||||||
@@ -63,4 +63,4 @@ If the user is not signed in no authorization header is set. If no authorization
|
|||||||
|
|
||||||
## TypeScript Support
|
## TypeScript Support
|
||||||
|
|
||||||
The Nhost JS SDK has TypeScript typings included. You don’t have to import types separately.
|
The Nhost JavaScript client is written in TypeScript and has full TypeScript support.
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
---
|
---
|
||||||
title: 'Overview'
|
title: 'Next.js'
|
||||||
sidebar_position: 1
|
sidebar_position: 1
|
||||||
---
|
---
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
---
|
---
|
||||||
title: 'Overview'
|
title: 'React'
|
||||||
sidebar_position: 1
|
sidebar_position: 1
|
||||||
---
|
---
|
||||||
|
|
||||||
@@ -31,20 +31,27 @@ yarn add @nhost/react graphql
|
|||||||
|
|
||||||
## Initializing
|
## Initializing
|
||||||
|
|
||||||
Initialize a single `nhost` instance and wrap your app with the `NhostReactProvider`.
|
After installation, initialize a single Nhost Client (`nhost`) under `src/lib/nhost.js`.
|
||||||
|
|
||||||
|
```jsx title=src/lib/nhost.js
|
||||||
|
import { NhostClient } from '@nhost/react'
|
||||||
|
const nhost = new NhostClient({
|
||||||
|
backendUrl: '<Your Nhost Backend URL>'
|
||||||
|
})
|
||||||
|
export { nhost }
|
||||||
|
```
|
||||||
|
|
||||||
|
Import `nhost` and wrap your app with the `NhostReactProvider`.
|
||||||
|
|
||||||
```jsx title=src/App.tsx
|
```jsx title=src/App.tsx
|
||||||
import React from 'react'
|
import React from 'react'
|
||||||
import ReactDOM from 'react-dom'
|
import ReactDOM from 'react-dom'
|
||||||
|
|
||||||
import { NhostClient, NhostReactProvider } from '@nhost/react'
|
import { NhostClient, NhostReactProvider } from '@nhost/react'
|
||||||
|
import { nhost } from './lib/nhost'
|
||||||
|
|
||||||
import App from './App'
|
import App from './App'
|
||||||
|
|
||||||
const nhost = new NhostClient({
|
|
||||||
backendUrl: '<Your Nhost Backend URL>'
|
|
||||||
})
|
|
||||||
|
|
||||||
ReactDOM.render(
|
ReactDOM.render(
|
||||||
<React.StrictMode>
|
<React.StrictMode>
|
||||||
<NhostReactProvider nhost={nhost}>
|
<NhostReactProvider nhost={nhost}>
|
||||||
@@ -53,8 +60,11 @@ ReactDOM.render(
|
|||||||
</React.StrictMode>,
|
</React.StrictMode>,
|
||||||
document.getElementById('root')
|
document.getElementById('root')
|
||||||
)
|
)
|
||||||
|
export { nhost }
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
:::info
|
:::info
|
||||||
|
|
||||||
The `nhost` instance created with the `NhostClient` above is the same as the [JavaScript Nhost client](/reference/javascript).
|
The `nhost` instance created with the `NhostClient` above is the same as the [JavaScript Nhost client](/reference/javascript).
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
---
|
---
|
||||||
title: 'Overview'
|
title: 'Vue'
|
||||||
sidebar_position: 1
|
sidebar_position: 1
|
||||||
---
|
---
|
||||||
|
|
||||||
|
|||||||
@@ -4,19 +4,28 @@
|
|||||||
const lightCodeTheme = require('prism-react-renderer/themes/github')
|
const lightCodeTheme = require('prism-react-renderer/themes/github')
|
||||||
const darkCodeTheme = require('prism-react-renderer/themes/dracula')
|
const darkCodeTheme = require('prism-react-renderer/themes/dracula')
|
||||||
|
|
||||||
|
const getBaseUrl = () => {
|
||||||
|
if (process.env.VERCEL_ENV === 'production') {
|
||||||
|
return 'https://docs.nhost.io'
|
||||||
|
} else if (process.env.VERCEL_ENV === 'preview') {
|
||||||
|
return `https://${process.env.VERCEL_URL}`
|
||||||
|
} else {
|
||||||
|
return `http://localhost:3000`
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/** @type {import('@docusaurus/types').Config} */
|
/** @type {import('@docusaurus/types').Config} */
|
||||||
const config = {
|
const config = {
|
||||||
title: 'Nhost Docs',
|
title: 'Nhost Docs',
|
||||||
tagline:
|
tagline: 'Nhost is an open source Firebase alternative with GraphQL.',
|
||||||
'Nhost is an open-source, real-time, server-less backend platform for building reliable apps that scale with your business.',
|
url: getBaseUrl(),
|
||||||
url: 'https://docs.nhost.io',
|
|
||||||
trailingSlash: false,
|
trailingSlash: false,
|
||||||
baseUrl: '/',
|
baseUrl: '/',
|
||||||
onBrokenLinks: 'throw',
|
onBrokenLinks: 'throw',
|
||||||
onBrokenMarkdownLinks: 'warn',
|
onBrokenMarkdownLinks: 'warn',
|
||||||
favicon: 'img/favicon.png',
|
favicon: 'img/favicon.png',
|
||||||
organizationName: 'nhost', // Usually your GitHub org/user name.
|
organizationName: 'nhost',
|
||||||
projectName: 'docs', // Usually your repo name.
|
projectName: 'docs',
|
||||||
|
|
||||||
presets: [
|
presets: [
|
||||||
[
|
[
|
||||||
@@ -33,7 +42,6 @@ const config = {
|
|||||||
breadcrumbs: false,
|
breadcrumbs: false,
|
||||||
sidebarPath: require.resolve('./sidebars.js'),
|
sidebarPath: require.resolve('./sidebars.js'),
|
||||||
remarkPlugins: [require('mdx-mermaid')],
|
remarkPlugins: [require('mdx-mermaid')],
|
||||||
// Please change this to your repo.
|
|
||||||
editUrl: 'https://github.com/nhost/nhost/edit/main/docs/'
|
editUrl: 'https://github.com/nhost/nhost/edit/main/docs/'
|
||||||
},
|
},
|
||||||
theme: {
|
theme: {
|
||||||
@@ -46,17 +54,13 @@ const config = {
|
|||||||
themeConfig:
|
themeConfig:
|
||||||
/** @type {import('@docusaurus/preset-classic').ThemeConfig} */
|
/** @type {import('@docusaurus/preset-classic').ThemeConfig} */
|
||||||
({
|
({
|
||||||
|
image: 'img/splash.png',
|
||||||
colorMode: {
|
colorMode: {
|
||||||
defaultMode: 'light',
|
defaultMode: 'light',
|
||||||
disableSwitch: false,
|
disableSwitch: false,
|
||||||
respectPrefersColorScheme: true
|
respectPrefersColorScheme: true
|
||||||
},
|
},
|
||||||
metadata: [
|
metadata: [{ name: 'robots', content: 'max-image-preview:large' }],
|
||||||
{
|
|
||||||
name: 'og:image',
|
|
||||||
content: 'https://docs.nhost.io/img/splash.png'
|
|
||||||
}
|
|
||||||
],
|
|
||||||
navbar: {
|
navbar: {
|
||||||
hideOnScroll: true,
|
hideOnScroll: true,
|
||||||
logo: {
|
logo: {
|
||||||
|
|||||||
BIN
docs/static/img/og/platform/architecture.png
vendored
Normal file
|
After Width: | Height: | Size: 159 KiB |
BIN
docs/static/img/og/platform/authentication.png
vendored
Normal file
|
After Width: | Height: | Size: 159 KiB |
BIN
docs/static/img/og/platform/cli.png
vendored
Normal file
|
After Width: | Height: | Size: 155 KiB |
BIN
docs/static/img/og/platform/database.png
vendored
Normal file
|
After Width: | Height: | Size: 159 KiB |
BIN
docs/static/img/og/platform/email-templates.png
vendored
Normal file
|
After Width: | Height: | Size: 160 KiB |
BIN
docs/static/img/og/platform/environment-variables.png
vendored
Normal file
|
After Width: | Height: | Size: 161 KiB |
BIN
docs/static/img/og/platform/event-triggers.png
vendored
Normal file
|
After Width: | Height: | Size: 160 KiB |
BIN
docs/static/img/og/platform/get-started-with-nhost-cli.png
vendored
Normal file
|
After Width: | Height: | Size: 163 KiB |
BIN
docs/static/img/og/platform/github-integration.png
vendored
Normal file
|
After Width: | Height: | Size: 160 KiB |
BIN
docs/static/img/og/platform/graphql.png
vendored
Normal file
|
After Width: | Height: | Size: 158 KiB |
BIN
docs/static/img/og/platform/introduction-to-nhost.png
vendored
Normal file
|
After Width: | Height: | Size: 160 KiB |
BIN
docs/static/img/og/platform/permissions.png
vendored
Normal file
|
After Width: | Height: | Size: 159 KiB |
BIN
docs/static/img/og/platform/quickstart-nextjs.png
vendored
Normal file
|
After Width: | Height: | Size: 166 KiB |
BIN
docs/static/img/og/platform/quickstart-react.png
vendored
Normal file
|
After Width: | Height: | Size: 168 KiB |
BIN
docs/static/img/og/platform/quickstart-redwoodjs.png
vendored
Normal file
|
After Width: | Height: | Size: 174 KiB |
BIN
docs/static/img/og/platform/quickstart-vue.png
vendored
Normal file
|
After Width: | Height: | Size: 166 KiB |
BIN
docs/static/img/og/platform/serverless-functions.png
vendored
Normal file
|
After Width: | Height: | Size: 163 KiB |
BIN
docs/static/img/og/platform/sign-in-methods.png
vendored
Normal file
|
After Width: | Height: | Size: 161 KiB |
BIN
docs/static/img/og/platform/sign-in-with-email-and-password.png
vendored
Normal file
|
After Width: | Height: | Size: 165 KiB |
BIN
docs/static/img/og/platform/sign-in-with-facebook.png
vendored
Normal file
|
After Width: | Height: | Size: 166 KiB |
BIN
docs/static/img/og/platform/sign-in-with-github.png
vendored
Normal file
|
After Width: | Height: | Size: 164 KiB |
BIN
docs/static/img/og/platform/sign-in-with-google.png
vendored
Normal file
|
After Width: | Height: | Size: 167 KiB |
BIN
docs/static/img/og/platform/sign-in-with-linkedin.png
vendored
Normal file
|
After Width: | Height: | Size: 163 KiB |
BIN
docs/static/img/og/platform/sign-in-with-magic-link.png
vendored
Normal file
|
After Width: | Height: | Size: 163 KiB |
BIN
docs/static/img/og/platform/sign-in-with-phone-number-sms.png
vendored
Normal file
|
After Width: | Height: | Size: 166 KiB |
BIN
docs/static/img/og/platform/sign-in-with-spotify.png
vendored
Normal file
|
After Width: | Height: | Size: 166 KiB |
BIN
docs/static/img/og/platform/storage.png
vendored
Normal file
|
After Width: | Height: | Size: 159 KiB |
BIN
docs/static/img/og/platform/tokens.png
vendored
Normal file
|
After Width: | Height: | Size: 157 KiB |
BIN
docs/static/img/og/platform/users.png
vendored
Normal file
|
After Width: | Height: | Size: 157 KiB |
@@ -5,6 +5,7 @@ module.exports = {
|
|||||||
'plugin:@next/next/recommended'
|
'plugin:@next/next/recommended'
|
||||||
],
|
],
|
||||||
rules: {
|
rules: {
|
||||||
'react/react-in-jsx-scope': 'off'
|
'react/react-in-jsx-scope': 'off',
|
||||||
|
'import/extensions': 'off'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,7 +15,7 @@
|
|||||||
<script lang="ts">
|
<script lang="ts">
|
||||||
import { computed, defineComponent } from 'vue'
|
import { computed, defineComponent } from 'vue'
|
||||||
|
|
||||||
import { gql } from '@apollo/client/core'
|
import { gql } from '@apollo/client/core/index.js'
|
||||||
import { useAuthenticated } from '@nhost/vue'
|
import { useAuthenticated } from '@nhost/vue'
|
||||||
import { useQuery } from '@vue/apollo-composable'
|
import { useQuery } from '@vue/apollo-composable'
|
||||||
|
|
||||||
|
|||||||
3
examples/vue-quickstart/.eslintrc.js
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
module.exports = {
|
||||||
|
extends: ['../../config/.eslintrc.vue']
|
||||||
|
}
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { gql } from '@apollo/client/core'
|
import { gql } from '@apollo/client/core/index.js'
|
||||||
import { useNhostClient, useUserId } from '@nhost/vue'
|
import { useNhostClient, useUserId } from '@nhost/vue'
|
||||||
import { useMutation, useSubscription } from '@vue/apollo-composable'
|
import { useMutation, useSubscription } from '@vue/apollo-composable'
|
||||||
import { computed, ref } from 'vue'
|
import { computed, ref } from 'vue'
|
||||||
@@ -18,7 +18,10 @@ const GET_USER_SUBSCRIPTION = gql`
|
|||||||
`
|
`
|
||||||
const id = useUserId()
|
const id = useUserId()
|
||||||
|
|
||||||
const { result } = useSubscription(GET_USER_SUBSCRIPTION, computed(() => ({ id: id.value })))
|
const { result } = useSubscription(
|
||||||
|
GET_USER_SUBSCRIPTION,
|
||||||
|
computed(() => ({ id: id.value }))
|
||||||
|
)
|
||||||
const user = computed(() => result.value?.user)
|
const user = computed(() => result.value?.user)
|
||||||
|
|
||||||
const UPDATE_USER_MUTATION = gql`
|
const UPDATE_USER_MUTATION = gql`
|
||||||
@@ -42,13 +45,12 @@ const updateUserProfile = async (event: Event) => {
|
|||||||
displayName: `${firstName.value} ${lastName.value}`.trim(),
|
displayName: `${firstName.value} ${lastName.value}`.trim(),
|
||||||
metadata: {
|
metadata: {
|
||||||
firstName: firstName.value,
|
firstName: firstName.value,
|
||||||
lastName: lastName.value,
|
lastName: lastName.value
|
||||||
},
|
}
|
||||||
})
|
})
|
||||||
await nhost.auth.refreshSession()
|
await nhost.auth.refreshSession()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
@@ -59,15 +61,11 @@ const updateUserProfile = async (event: Event) => {
|
|||||||
<em text-sm op75>Quickstart</em>
|
<em text-sm op75>Quickstart</em>
|
||||||
</p>
|
</p>
|
||||||
<div v-if="user" py-4>
|
<div v-if="user" py-4>
|
||||||
<p>
|
<p>Hello, {{ user.displayName }}. Your email is {{ user.email }}.</p>
|
||||||
Hello, {{ user.displayName }}. Your email is {{ user.email }}.
|
|
||||||
</p>
|
|
||||||
<form @submit="updateUserProfile">
|
<form @submit="updateUserProfile">
|
||||||
<input v-model="firstName" placeholder="First name" class="input"><br>
|
<input v-model="firstName" placeholder="First name" class="input" /><br />
|
||||||
<input v-model="lastName" placeholder="Last name" class="input"><br>
|
<input v-model="lastName" placeholder="Last name" class="input" /><br />
|
||||||
<button class="btn-submit" :disabled="loading">
|
<button class="btn-submit" :disabled="loading">Save</button>
|
||||||
Save
|
|
||||||
</button>
|
|
||||||
<div v-if="error">
|
<div v-if="error">
|
||||||
{{ error.message }}
|
{{ error.message }}
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -11,12 +11,12 @@ import Unocss from 'unocss/vite'
|
|||||||
export default defineConfig({
|
export default defineConfig({
|
||||||
resolve: {
|
resolve: {
|
||||||
alias: {
|
alias: {
|
||||||
'~/': `${path.resolve(__dirname, 'src')}/`,
|
'~/': `${path.resolve(__dirname, 'src')}/`
|
||||||
},
|
}
|
||||||
},
|
},
|
||||||
plugins: [
|
plugins: [
|
||||||
Vue({
|
Vue({
|
||||||
reactivityTransform: true,
|
reactivityTransform: true
|
||||||
}),
|
}),
|
||||||
|
|
||||||
// https://github.com/hannoeru/vite-plugin-pages
|
// https://github.com/hannoeru/vite-plugin-pages
|
||||||
@@ -25,21 +25,21 @@ export default defineConfig({
|
|||||||
// https://github.com/antfu/unplugin-auto-import
|
// https://github.com/antfu/unplugin-auto-import
|
||||||
AutoImport({
|
AutoImport({
|
||||||
imports: ['vue/macros', 'vue-router', '@vueuse/core'],
|
imports: ['vue/macros', 'vue-router', '@vueuse/core'],
|
||||||
dts: true,
|
dts: true
|
||||||
}),
|
}),
|
||||||
|
|
||||||
// https://github.com/antfu/vite-plugin-components
|
// https://github.com/antfu/vite-plugin-components
|
||||||
Components({
|
Components({
|
||||||
dts: true,
|
dts: true
|
||||||
}),
|
}),
|
||||||
|
|
||||||
// https://github.com/antfu/unocss
|
// https://github.com/antfu/unocss
|
||||||
// see unocss.config.ts for config
|
// see unocss.config.ts for config
|
||||||
Unocss(),
|
Unocss()
|
||||||
],
|
],
|
||||||
|
|
||||||
// https://github.com/vitest-dev/vitest
|
// https://github.com/vitest-dev/vitest
|
||||||
test: {
|
test: {
|
||||||
environment: 'jsdom',
|
environment: 'jsdom'
|
||||||
},
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -54,7 +54,6 @@
|
|||||||
"@typescript-eslint/parser": "^5.22.0",
|
"@typescript-eslint/parser": "^5.22.0",
|
||||||
"@vitejs/plugin-react": "^1.3.2",
|
"@vitejs/plugin-react": "^1.3.2",
|
||||||
"c8": "^7.11.2",
|
"c8": "^7.11.2",
|
||||||
"cpy-cli": "^4.1.0",
|
|
||||||
"eslint": "^8.14.0",
|
"eslint": "^8.14.0",
|
||||||
"eslint-config-react-app": "^7.0.1",
|
"eslint-config-react-app": "^7.0.1",
|
||||||
"eslint-plugin-flowtype": "^8.0.3",
|
"eslint-plugin-flowtype": "^8.0.3",
|
||||||
|
|||||||
@@ -1,5 +1,22 @@
|
|||||||
# @nhost/apollo
|
# @nhost/apollo
|
||||||
|
|
||||||
|
## 0.5.11
|
||||||
|
|
||||||
|
### Patch Changes
|
||||||
|
|
||||||
|
- 1b37b9f6: fix: ESM import path fixes
|
||||||
|
- Updated dependencies [1b37b9f6]
|
||||||
|
- @nhost/nhost-js@1.2.2
|
||||||
|
|
||||||
|
## 0.5.10
|
||||||
|
|
||||||
|
### Patch Changes
|
||||||
|
|
||||||
|
- 78341491: fix: Next.js and React issues with ESM packages
|
||||||
|
chore: Updated output bundle names
|
||||||
|
- Updated dependencies [78341491]
|
||||||
|
- @nhost/nhost-js@1.2.1
|
||||||
|
|
||||||
## 0.5.9
|
## 0.5.9
|
||||||
|
|
||||||
### Patch Changes
|
### Patch Changes
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@nhost/apollo",
|
"name": "@nhost/apollo",
|
||||||
"version": "0.5.9",
|
"version": "0.5.11",
|
||||||
"description": "Nhost Apollo Client library",
|
"description": "Nhost Apollo Client library",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
@@ -22,7 +22,7 @@
|
|||||||
"url": "https://github.com/nhost/nhost.git"
|
"url": "https://github.com/nhost/nhost.git"
|
||||||
},
|
},
|
||||||
"main": "dist/index.cjs.js",
|
"main": "dist/index.cjs.js",
|
||||||
"module": "dist/index.mjs",
|
"module": "dist/index.esm.mjs",
|
||||||
"types": "dist/index.d.ts",
|
"types": "dist/index.d.ts",
|
||||||
"source": "src/index.ts",
|
"source": "src/index.ts",
|
||||||
"files": [
|
"files": [
|
||||||
@@ -33,10 +33,10 @@
|
|||||||
"exports": {
|
"exports": {
|
||||||
".": {
|
".": {
|
||||||
"node": {
|
"node": {
|
||||||
"import": "./dist/index.mjs",
|
"import": "./dist/index.esm.mjs",
|
||||||
"require": "./dist/index.cjs.js"
|
"require": "./dist/index.cjs.js"
|
||||||
},
|
},
|
||||||
"default": "./dist/index.es.js"
|
"default": "./dist/index.esm.js"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"publishConfig": {
|
"publishConfig": {
|
||||||
@@ -45,7 +45,7 @@
|
|||||||
"scripts": {
|
"scripts": {
|
||||||
"dev": "vite build --config ../../config/vite.lib.dev.config.js",
|
"dev": "vite build --config ../../config/vite.lib.dev.config.js",
|
||||||
"build": "run-p build:lib build:umd",
|
"build": "run-p build:lib build:umd",
|
||||||
"build:lib": "vite build --config ../../config/vite.lib.config.js && cpy --flat dist/index.mjs dist --rename=index.es.js && cpy --flat dist/index.mjs.map dist --rename index.es.js.map",
|
"build:lib": "vite build --config ../../config/vite.lib.config.js",
|
||||||
"build:umd": "vite build --config ../../config/vite.lib.umd.config.js",
|
"build:umd": "vite build --config ../../config/vite.lib.umd.config.js",
|
||||||
"test": "vitest run --config ../../config/vite.lib.config.js",
|
"test": "vitest run --config ../../config/vite.lib.config.js",
|
||||||
"test:watch": "vitest --config ../../config/vite.lib.config.js",
|
"test:watch": "vitest --config ../../config/vite.lib.config.js",
|
||||||
|
|||||||
@@ -7,10 +7,10 @@ import {
|
|||||||
RequestHandler,
|
RequestHandler,
|
||||||
split,
|
split,
|
||||||
WatchQueryFetchPolicy
|
WatchQueryFetchPolicy
|
||||||
} from '@apollo/client/core'
|
} from '@apollo/client/core/index.js'
|
||||||
import { setContext } from '@apollo/client/link/context'
|
import { setContext } from '@apollo/client/link/context/index.js'
|
||||||
import { GraphQLWsLink } from '@apollo/client/link/subscriptions'
|
import { GraphQLWsLink } from '@apollo/client/link/subscriptions/index.js'
|
||||||
import { getMainDefinition } from '@apollo/client/utilities'
|
import { getMainDefinition } from '@apollo/client/utilities/index.js'
|
||||||
import { NhostClient } from '@nhost/nhost-js'
|
import { NhostClient } from '@nhost/nhost-js'
|
||||||
|
|
||||||
import { createRestartableClient } from './ws'
|
import { createRestartableClient } from './ws'
|
||||||
|
|||||||
@@ -1,5 +1,18 @@
|
|||||||
# @nhost/core
|
# @nhost/core
|
||||||
|
|
||||||
|
## 0.6.3
|
||||||
|
|
||||||
|
### Patch Changes
|
||||||
|
|
||||||
|
- 1b37b9f6: fix: ESM import path fixes
|
||||||
|
|
||||||
|
## 0.6.2
|
||||||
|
|
||||||
|
### Patch Changes
|
||||||
|
|
||||||
|
- 78341491: fix: Next.js and React issues with ESM packages
|
||||||
|
chore: Updated output bundle names
|
||||||
|
|
||||||
## 0.6.1
|
## 0.6.1
|
||||||
|
|
||||||
### Patch Changes
|
### Patch Changes
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@nhost/core",
|
"name": "@nhost/core",
|
||||||
"version": "0.6.1",
|
"version": "0.6.3",
|
||||||
"description": "Nhost core client library",
|
"description": "Nhost core client library",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
@@ -21,7 +21,7 @@
|
|||||||
"url": "https://github.com/nhost/nhost.git"
|
"url": "https://github.com/nhost/nhost.git"
|
||||||
},
|
},
|
||||||
"main": "dist/index.cjs.js",
|
"main": "dist/index.cjs.js",
|
||||||
"module": "dist/index.mjs",
|
"module": "dist/index.esm.mjs",
|
||||||
"types": "dist/index.d.ts",
|
"types": "dist/index.d.ts",
|
||||||
"source": "src/index.ts",
|
"source": "src/index.ts",
|
||||||
"files": [
|
"files": [
|
||||||
@@ -32,10 +32,10 @@
|
|||||||
"exports": {
|
"exports": {
|
||||||
".": {
|
".": {
|
||||||
"node": {
|
"node": {
|
||||||
"import": "./dist/index.mjs",
|
"import": "./dist/index.esm.mjs",
|
||||||
"require": "./dist/index.cjs.js"
|
"require": "./dist/index.cjs.js"
|
||||||
},
|
},
|
||||||
"default": "./dist/index.es.js"
|
"default": "./dist/index.esm.js"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"publishConfig": {
|
"publishConfig": {
|
||||||
@@ -44,7 +44,7 @@
|
|||||||
"scripts": {
|
"scripts": {
|
||||||
"dev": "vite build --config ../../config/vite.lib.dev.config.js",
|
"dev": "vite build --config ../../config/vite.lib.dev.config.js",
|
||||||
"build": "run-p build:lib build:umd",
|
"build": "run-p build:lib build:umd",
|
||||||
"build:lib": "vite build --config ../../config/vite.lib.config.js && cpy --flat dist/index.mjs dist --rename=index.es.js && cpy --flat dist/index.mjs.map dist --rename index.es.js.map",
|
"build:lib": "vite build --config ../../config/vite.lib.config.js",
|
||||||
"build:umd": "vite build --config ../../config/vite.lib.umd.config.js",
|
"build:umd": "vite build --config ../../config/vite.lib.umd.config.js",
|
||||||
"test": "vitest run --config ../../config/vite.lib.config.js",
|
"test": "vitest run --config ../../config/vite.lib.config.js",
|
||||||
"test:watch": "vitest --config ../../config/vite.lib.config.js",
|
"test:watch": "vitest --config ../../config/vite.lib.config.js",
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import faker from '@faker-js/faker'
|
import faker from '@faker-js/faker'
|
||||||
import { interpret } from 'xstate'
|
import { interpret } from 'xstate'
|
||||||
import { waitFor } from 'xstate/lib/waitFor'
|
import { waitFor } from 'xstate/lib/waitFor.js'
|
||||||
import { AuthClient } from '../src/client'
|
import { AuthClient } from '../src/client'
|
||||||
import { INVALID_EMAIL_ERROR } from '../src/errors'
|
import { INVALID_EMAIL_ERROR } from '../src/errors'
|
||||||
import { createAuthMachine, createChangeEmailMachine } from '../src/machines'
|
import { createAuthMachine, createChangeEmailMachine } from '../src/machines'
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import faker from '@faker-js/faker'
|
import faker from '@faker-js/faker'
|
||||||
import { interpret } from 'xstate'
|
import { interpret } from 'xstate'
|
||||||
import { waitFor } from 'xstate/lib/waitFor'
|
import { waitFor } from 'xstate/lib/waitFor.js'
|
||||||
import { AuthClient } from '../src/client'
|
import { AuthClient } from '../src/client'
|
||||||
import { INVALID_PASSWORD_ERROR } from '../src/errors'
|
import { INVALID_PASSWORD_ERROR } from '../src/errors'
|
||||||
import { createAuthMachine, createChangePasswordMachine } from '../src/machines'
|
import { createAuthMachine, createChangePasswordMachine } from '../src/machines'
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
import faker from '@faker-js/faker'
|
import faker from '@faker-js/faker'
|
||||||
import { afterAll, afterEach, beforeAll, expect, test } from 'vitest'
|
import { afterAll, afterEach, beforeAll, expect, test } from 'vitest'
|
||||||
import { interpret } from 'xstate'
|
import { interpret } from 'xstate'
|
||||||
import { waitFor } from 'xstate/lib/waitFor'
|
import { waitFor } from 'xstate/lib/waitFor.js'
|
||||||
import { AuthClient } from '../src/client'
|
import { AuthClient } from '../src/client'
|
||||||
import { INVALID_MFA_CODE_ERROR, INVALID_MFA_TYPE_ERROR } from '../src/errors'
|
import { INVALID_MFA_CODE_ERROR, INVALID_MFA_TYPE_ERROR } from '../src/errors'
|
||||||
import { createAuthMachine, createEnableMfaMachine } from '../src/machines'
|
import { createAuthMachine, createEnableMfaMachine } from '../src/machines'
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
import faker from '@faker-js/faker'
|
import faker from '@faker-js/faker'
|
||||||
import { afterAll, afterEach, beforeAll, expect, test } from 'vitest'
|
import { afterAll, afterEach, beforeAll, expect, test } from 'vitest'
|
||||||
import { interpret } from 'xstate'
|
import { interpret } from 'xstate'
|
||||||
import { waitFor } from 'xstate/lib/waitFor'
|
import { waitFor } from 'xstate/lib/waitFor.js'
|
||||||
import { createAuthMachine } from '../src/machines'
|
import { createAuthMachine } from '../src/machines'
|
||||||
import { Typegen0 } from '../src/machines/index.typegen'
|
import { Typegen0 } from '../src/machines/index.typegen'
|
||||||
import { BASE_URL } from './helpers/config'
|
import { BASE_URL } from './helpers/config'
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import faker from '@faker-js/faker'
|
import faker from '@faker-js/faker'
|
||||||
import { interpret } from 'xstate'
|
import { interpret } from 'xstate'
|
||||||
import { waitFor } from 'xstate/lib/waitFor'
|
import { waitFor } from 'xstate/lib/waitFor.js'
|
||||||
import { INVALID_EMAIL_ERROR, INVALID_PASSWORD_ERROR } from '../src/errors'
|
import { INVALID_EMAIL_ERROR, INVALID_PASSWORD_ERROR } from '../src/errors'
|
||||||
import { createAuthMachine } from '../src/machines'
|
import { createAuthMachine } from '../src/machines'
|
||||||
import { Typegen0 } from '../src/machines/index.typegen'
|
import { Typegen0 } from '../src/machines/index.typegen'
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import faker from '@faker-js/faker'
|
import faker from '@faker-js/faker'
|
||||||
import { interpret } from 'xstate'
|
import { interpret } from 'xstate'
|
||||||
import { waitFor } from 'xstate/lib/waitFor'
|
import { waitFor } from 'xstate/lib/waitFor.js'
|
||||||
import { INVALID_EMAIL_ERROR } from '../src/errors'
|
import { INVALID_EMAIL_ERROR } from '../src/errors'
|
||||||
import { createAuthMachine } from '../src/machines'
|
import { createAuthMachine } from '../src/machines'
|
||||||
import { Typegen0 } from '../src/machines/index.typegen'
|
import { Typegen0 } from '../src/machines/index.typegen'
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import faker from '@faker-js/faker'
|
import faker from '@faker-js/faker'
|
||||||
import { interpret } from 'xstate'
|
import { interpret } from 'xstate'
|
||||||
import { waitFor } from 'xstate/lib/waitFor'
|
import { waitFor } from 'xstate/lib/waitFor.js'
|
||||||
import { INVALID_PHONE_NUMBER_ERROR } from '../src/errors'
|
import { INVALID_PHONE_NUMBER_ERROR } from '../src/errors'
|
||||||
import { createAuthMachine } from '../src/machines'
|
import { createAuthMachine } from '../src/machines'
|
||||||
import { Typegen0 } from '../src/machines/index.typegen'
|
import { Typegen0 } from '../src/machines/index.typegen'
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
import faker from '@faker-js/faker'
|
import faker from '@faker-js/faker'
|
||||||
import { afterAll, afterEach, beforeAll, beforeEach, describe, test, vi } from 'vitest'
|
import { afterAll, afterEach, beforeAll, beforeEach, describe, test, vi } from 'vitest'
|
||||||
import { BaseActionObject, interpret, Interpreter, ResolveTypegenMeta, ServiceMap } from 'xstate'
|
import { BaseActionObject, interpret, Interpreter, ResolveTypegenMeta, ServiceMap } from 'xstate'
|
||||||
import { waitFor } from 'xstate/lib/waitFor'
|
import { waitFor } from 'xstate/lib/waitFor.js'
|
||||||
import {
|
import {
|
||||||
NHOST_JWT_EXPIRES_AT_KEY,
|
NHOST_JWT_EXPIRES_AT_KEY,
|
||||||
NHOST_REFRESH_TOKEN_KEY,
|
NHOST_REFRESH_TOKEN_KEY,
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import faker from '@faker-js/faker'
|
import faker from '@faker-js/faker'
|
||||||
import { interpret } from 'xstate'
|
import { interpret } from 'xstate'
|
||||||
import { waitFor } from 'xstate/lib/waitFor'
|
import { waitFor } from 'xstate/lib/waitFor.js'
|
||||||
import { AuthClient } from '../src/client'
|
import { AuthClient } from '../src/client'
|
||||||
import { INVALID_EMAIL_ERROR } from '../src/errors'
|
import { INVALID_EMAIL_ERROR } from '../src/errors'
|
||||||
import { createResetPasswordMachine } from '../src/machines'
|
import { createResetPasswordMachine } from '../src/machines'
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import faker from '@faker-js/faker'
|
import faker from '@faker-js/faker'
|
||||||
import { interpret } from 'xstate'
|
import { interpret } from 'xstate'
|
||||||
import { waitFor } from 'xstate/lib/waitFor'
|
import { waitFor } from 'xstate/lib/waitFor.js'
|
||||||
import { AuthClient } from '../src/client'
|
import { AuthClient } from '../src/client'
|
||||||
import { INVALID_EMAIL_ERROR } from '../src/errors'
|
import { INVALID_EMAIL_ERROR } from '../src/errors'
|
||||||
import { createSendVerificationEmailMachine } from '../src/machines'
|
import { createSendVerificationEmailMachine } from '../src/machines'
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import faker from '@faker-js/faker'
|
import faker from '@faker-js/faker'
|
||||||
import { interpret } from 'xstate'
|
import { interpret } from 'xstate'
|
||||||
import { waitFor } from 'xstate/lib/waitFor'
|
import { waitFor } from 'xstate/lib/waitFor.js'
|
||||||
import { NHOST_REFRESH_TOKEN_KEY } from '../src/constants'
|
import { NHOST_REFRESH_TOKEN_KEY } from '../src/constants'
|
||||||
import { createAuthMachine } from '../src/machines'
|
import { createAuthMachine } from '../src/machines'
|
||||||
import { Typegen0 } from '../src/machines/index.typegen'
|
import { Typegen0 } from '../src/machines/index.typegen'
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import faker from '@faker-js/faker'
|
import faker from '@faker-js/faker'
|
||||||
import { interpret } from 'xstate'
|
import { interpret } from 'xstate'
|
||||||
import { waitFor } from 'xstate/lib/waitFor'
|
import { waitFor } from 'xstate/lib/waitFor.js'
|
||||||
import { INVALID_EMAIL_ERROR, INVALID_PASSWORD_ERROR } from '../src/errors'
|
import { INVALID_EMAIL_ERROR, INVALID_PASSWORD_ERROR } from '../src/errors'
|
||||||
import { createAuthMachine } from '../src/machines'
|
import { createAuthMachine } from '../src/machines'
|
||||||
import { Typegen0 } from '../src/machines/index.typegen'
|
import { Typegen0 } from '../src/machines/index.typegen'
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import faker from '@faker-js/faker'
|
import faker from '@faker-js/faker'
|
||||||
import { interpret } from 'xstate'
|
import { interpret } from 'xstate'
|
||||||
import { waitFor } from 'xstate/lib/waitFor'
|
import { waitFor } from 'xstate/lib/waitFor.js'
|
||||||
import { INVALID_PHONE_NUMBER_ERROR } from '../src/errors'
|
import { INVALID_PHONE_NUMBER_ERROR } from '../src/errors'
|
||||||
import { createAuthMachine } from '../src/machines'
|
import { createAuthMachine } from '../src/machines'
|
||||||
import { Typegen0 } from '../src/machines/index.typegen'
|
import { Typegen0 } from '../src/machines/index.typegen'
|
||||||
|
|||||||