Skip to content

Commit

Permalink
Merge branch 'dev' into feature/get-orgs-pagination
Browse files Browse the repository at this point in the history
  • Loading branch information
kobiowuquadri authored Jul 24, 2024
2 parents 755caf5 + e40c5cf commit b8df14a
Show file tree
Hide file tree
Showing 87 changed files with 7,705 additions and 1,326 deletions.
17 changes: 16 additions & 1 deletion .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,20 @@ SMTP_USER=
SMTP_PASSWORD=
SMTP_HOST=
SMTP_SERVICE=
TWILIO_SID=
TWILIO_AUTH_TOKEN=
TWILIO_PHONE_NUMBER=
TWILIO_ACCOUNT_SID=
TWILIO_AUTH_TOKEN=
TWILIO_AUTH_TOKEN=
GOOGLE_CLIENT_ID=
GOOGLE_CLIENT_SECRET=
#Redis Configuration
REDIS_HOST=
REDIS_PORT=

# Cloudinary setup
CLOUDINARY_CLOUD_NAME=
CLOUDINARY_API_KEY=
CLOUDINARY_API_SECRET=
=======
GOOGLE_AUTH_CALLBACK_URL=
6 changes: 5 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,8 @@ temp/
.env
env
src/entity
src/ormconfig.ts
src/ormconfig.ts
build
issueformat.md
requests.rest
package-lock.json
1 change: 1 addition & 0 deletions .husky/commit-msg
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
yarn commitlint ${1}
7 changes: 7 additions & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
yarn

yarn lint-staged

yarn test

yarn build
33 changes: 33 additions & 0 deletions commitlint.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
module.exports = {
parserPreset: "conventional-changelog-conventionalcommits",
extends: ["@commitlint/config-conventional"],
rules: {
"body-leading-blank": [1, "always"],
"body-max-line-length": [2, "always", 100],
"footer-leading-blank": [1, "always"],
"footer-max-line-length": [2, "always", 100],
"header-max-length": [2, "always", 100],
"subject-case": [2, "never", ["start-case", "pascal-case"]],
"subject-empty": [2, "never"],
"subject-full-stop": [2, "never", "."],
"type-case": [2, "always", "lower-case"],
"type-empty": [2, "never"],
"type-enum": [
2,
"always",
[
"build",
"chore",
"ci",
"docs",
"feat",
"fix",
"perf",
"refactor",
"revert",
"style",
"test",
],
],
},
};
7 changes: 3 additions & 4 deletions contributors.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@


Erasmus Tayviah (StarmannRassy)

- [Nainah23](https://github.com/Nainah23)
- Erasmus Tayviah (StarmannRassy)
- [Adekolu Samuel Samixx](https://github.com/samixYasuke)
175 changes: 121 additions & 54 deletions db/migrations/1721742344691-migration.ts

Large diffs are not rendered by default.

171 changes: 171 additions & 0 deletions docs/javascript-snippets.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,171 @@
# Javascript snippets

- `np` - nextPage
- `npssp` - nextPageServerSideProps
- `npsp` - nextPageStaticProps
- `npspth` - nextPageStaticPaths
- `nssp` - nextServerSideProps
- `nsp` - nextStaticProps
- `nspth` - nextStaticPaths
- `nip` - nextInitialProps
- `nimg` - nextImage
- `napp` - nextApp
- `ndoc` - nextDocument
- `napi` - nextApi
- `nmid` - nextMiddleware

## `np` - nextPage

```javascript
const FileName = ({}) => {
return <div></div>;
};

export default FileName;
```

## `npssp` - nextPageServerSideProps

```javascript
const FileName = ({}) => {
return <div></div>;
};

export const getServerSideProps = async (ctx) => {
return {
props: {},
};
};

export default FileName;
```

## `npsp` - nextPageStaticProps

```javascript
const FileName = ({}) => {
return <div></div>;
};

export const getStaticProps = async (ctx) => {
return {
props: {},
};
};

export default FileName;
```

## `npspth` - nextPageStaticPaths

```javascript
const FileName = ({}) => {
return <div></div>;
};

export const getStaticPaths = async () => {
return {
paths: [],
fallback: false,
};
};

export default FileName;
```

## `nssp` - nextServerSideProps

```javascript
export const getServerSideProps = async (ctx) => {
return {
props: {},
};
};
```

## `nsp` - nextStaticProps

```javascript
export const getStaticProps = async (ctx) => {
return {
props: {},
};
};
```

## `nspth` - nextStaticPaths

```javascript
export const getStaticPaths = async () => {
return {
paths: [],
fallback: false,
};
};
```

## `nip` - nextInitialProps

```javascript
FileName.getInitialProps = async (ctx) => {
return {};
};
```

## `nimg` - nextImage

```javascript
<Image src="" alt="" />
```

## `napp` - nextApp

```javascript
export default function MyApp({ Component, pageProps }) {
return <Component {...pageProps} />;
}
```

## `ndoc` - nextDocument

```javascript
import Document, { Html, Head, Main, NextScript } from "next/document";

class MyDocument extends Document {
static async getInitialProps(ctx) {
const initialProps = await Document.getInitialProps(ctx);
return { ...initialProps };
}

render() {
return (
<Html>
<Head />
<body>
<Main />
<NextScript />
</body>
</Html>
);
}
}

export default MyDocument;
```

## `napi` - nextApi

```javascript
export default async function handler(req, res) {}
```

## `nmid` - nextMiddleware

```javascript
import { NextResponse } from "next/server";
export async function middleware(request) {}

export const config = {
matcher: "/about/:path*",
};
```
Loading

0 comments on commit b8df14a

Please sign in to comment.