Skip to content

Commit

Permalink
feat: add in example code and extra instructions
Browse files Browse the repository at this point in the history
  • Loading branch information
crypblizz8 committed Oct 4, 2024
1 parent 2c4b487 commit 2d1032c
Show file tree
Hide file tree
Showing 31 changed files with 15,781 additions and 3,680 deletions.
3 changes: 3 additions & 0 deletions eslint.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,4 +40,7 @@ export default [
...eslintPluginJest.configs.recommended.rules,
},
},
{
ignores: ["examples/**/*"],
},
];
3 changes: 3 additions & 0 deletions examples/nextjs/.eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"extends": ["next/core-web-vitals", "next/typescript"]
}
36 changes: 36 additions & 0 deletions examples/nextjs/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.

# dependencies
/node_modules
/.pnp
.pnp.js
.yarn/install-state.gz

# testing
/coverage

# next.js
/.next/
/out/

# production
/build

# misc
.DS_Store
*.pem

# debug
npm-debug.log*
yarn-debug.log*
yarn-error.log*

# local env files
.env*.local

# vercel
.vercel

# typescript
*.tsbuildinfo
next-env.d.ts
19 changes: 19 additions & 0 deletions examples/nextjs/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
## Nextjs Example for Create Nillion App

First, run the development server:

```bash
npm run dev
# or
yarn dev
# or
pnpm dev
# or
bun dev
```

Open [http://localhost:3000](http://localhost:3000) with your browser to see the result.

### INFO

ADD MORE...
19 changes: 19 additions & 0 deletions examples/nextjs/next.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
/* eslint-disable */
/** @type {import("next").NextConfig} */
const nextConfig = {
async headers() {
return [
{
source: "/:path*",
// headers required for @nillion/client-wasm's wasm artefact
headers: [
{ key: "Cross-Origin-Embedder-Policy", value: "require-corp" },
{ key: "Cross-Origin-Opener-Policy", value: "same-origin" },
],
},
];
},
};

export default nextConfig;

Loading

0 comments on commit 2d1032c

Please sign in to comment.