Skip to content

Commit

Permalink
add explorer + indexer to all templates
Browse files Browse the repository at this point in the history
  • Loading branch information
karooolis committed Aug 22, 2024
1 parent f1d8d71 commit d28ad48
Show file tree
Hide file tree
Showing 20 changed files with 55 additions and 5 deletions.
Binary file added templates/phaser/indexer.db
Binary file not shown.
8 changes: 8 additions & 0 deletions templates/phaser/mprocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,11 @@ procs:
anvil:
cwd: packages/contracts
shell: anvil --base-fee 0 --block-time 2
indexer:
shell: rimraf $SQLITE_FILENAME && pnpm sqlite-indexer
env:
RPC_HTTP_URL: "http://127.0.0.1:8545"
FOLLOW_BLOCK_TAG: "latest"
SQLITE_FILENAME: "indexer.db"
explorer:
shell: pnpm explorer --worldsFile packages/contracts/worlds.json
2 changes: 2 additions & 0 deletions templates/phaser/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@
"devDependencies": {
"@latticexyz/cli": "link:../../packages/cli",
"@latticexyz/common": "link:../../packages/common",
"@latticexyz/explorer": "link:../../packages/explorer",
"@latticexyz/store-indexer": "link:../../packages/store-indexer",
"@types/debug": "4.1.7",
"@typescript-eslint/eslint-plugin": "7.1.1",
"@typescript-eslint/parser": "7.1.1",
Expand Down
2 changes: 1 addition & 1 deletion templates/phaser/packages/contracts/worlds.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"31337": {
"address": "0x4f4ddafbc93cf8d11a253f21ddbcf836139efdec"
"address": "0x8d8b6b8414e1e3dcfd4168561b9be6bd3bf6ec4b"
}
}
Binary file added templates/react-ecs/indexer.db
Binary file not shown.
8 changes: 8 additions & 0 deletions templates/react-ecs/mprocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,11 @@ procs:
anvil:
cwd: packages/contracts
shell: anvil --base-fee 0 --block-time 2
indexer:
shell: rimraf $SQLITE_FILENAME && pnpm sqlite-indexer
env:
RPC_HTTP_URL: "http://127.0.0.1:8545"
FOLLOW_BLOCK_TAG: "latest"
SQLITE_FILENAME: "indexer.db"
explorer:
shell: pnpm explorer --worldsFile packages/contracts/worlds.json
2 changes: 2 additions & 0 deletions templates/react-ecs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@
"devDependencies": {
"@latticexyz/cli": "link:../../packages/cli",
"@latticexyz/common": "link:../../packages/common",
"@latticexyz/explorer": "link:../../packages/explorer",
"@latticexyz/store-indexer": "link:../../packages/store-indexer",
"@types/debug": "4.1.7",
"@typescript-eslint/eslint-plugin": "7.1.1",
"@typescript-eslint/parser": "7.1.1",
Expand Down
2 changes: 1 addition & 1 deletion templates/react-ecs/packages/contracts/worlds.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"31337": {
"address": "0x4f4ddafbc93cf8d11a253f21ddbcf836139efdec"
"address": "0x8d8b6b8414e1e3dcfd4168561b9be6bd3bf6ec4b"
}
}
Binary file added templates/react/indexer.db
Binary file not shown.
8 changes: 8 additions & 0 deletions templates/react/mprocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,11 @@ procs:
anvil:
cwd: packages/contracts
shell: anvil --base-fee 0 --block-time 2
indexer:
shell: rimraf $SQLITE_FILENAME && pnpm sqlite-indexer
env:
RPC_HTTP_URL: "http://127.0.0.1:8545"
FOLLOW_BLOCK_TAG: "latest"
SQLITE_FILENAME: "indexer.db"
explorer:
shell: pnpm explorer --worldsFile packages/contracts/worlds.json
2 changes: 2 additions & 0 deletions templates/react/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@
"devDependencies": {
"@latticexyz/cli": "link:../../packages/cli",
"@latticexyz/common": "link:../../packages/common",
"@latticexyz/explorer": "link:../../packages/explorer",
"@latticexyz/store-indexer": "link:../../packages/store-indexer",
"@types/debug": "4.1.7",
"@typescript-eslint/eslint-plugin": "7.1.1",
"@typescript-eslint/parser": "7.1.1",
Expand Down
2 changes: 1 addition & 1 deletion templates/react/packages/contracts/worlds.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"31337": {
"address": "0x4f4ddafbc93cf8d11a253f21ddbcf836139efdec"
"address": "0x8d8b6b8414e1e3dcfd4168561b9be6bd3bf6ec4b"
}
}
Binary file added templates/threejs/indexer.db
Binary file not shown.
8 changes: 8 additions & 0 deletions templates/threejs/mprocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,11 @@ procs:
anvil:
cwd: packages/contracts
shell: anvil --base-fee 0 --block-time 2
indexer:
shell: rimraf $SQLITE_FILENAME && pnpm sqlite-indexer
env:
RPC_HTTP_URL: "http://127.0.0.1:8545"
FOLLOW_BLOCK_TAG: "latest"
SQLITE_FILENAME: "indexer.db"
explorer:
shell: pnpm explorer --worldsFile packages/contracts/worlds.json
2 changes: 2 additions & 0 deletions templates/threejs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@
"devDependencies": {
"@latticexyz/cli": "link:../../packages/cli",
"@latticexyz/common": "link:../../packages/common",
"@latticexyz/explorer": "link:../../packages/explorer",
"@latticexyz/store-indexer": "link:../../packages/store-indexer",
"@types/debug": "4.1.7",
"@typescript-eslint/eslint-plugin": "7.1.1",
"@typescript-eslint/parser": "7.1.1",
Expand Down
2 changes: 1 addition & 1 deletion templates/threejs/packages/contracts/worlds.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"31337": {
"address": "0x4f4ddafbc93cf8d11a253f21ddbcf836139efdec"
"address": "0x8d8b6b8414e1e3dcfd4168561b9be6bd3bf6ec4b"
}
}
Binary file added templates/vanilla/indexer.db
Binary file not shown.
8 changes: 8 additions & 0 deletions templates/vanilla/mprocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,11 @@ procs:
anvil:
cwd: packages/contracts
shell: anvil --base-fee 0 --block-time 2
indexer:
shell: rimraf $SQLITE_FILENAME && pnpm sqlite-indexer
env:
RPC_HTTP_URL: "http://127.0.0.1:8545"
FOLLOW_BLOCK_TAG: "latest"
SQLITE_FILENAME: "indexer.db"
explorer:
shell: pnpm explorer --worldsFile packages/contracts/worlds.json
2 changes: 2 additions & 0 deletions templates/vanilla/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@
"devDependencies": {
"@latticexyz/cli": "link:../../packages/cli",
"@latticexyz/common": "link:../../packages/common",
"@latticexyz/explorer": "link:../../packages/explorer",
"@latticexyz/store-indexer": "link:../../packages/store-indexer",
"@types/debug": "4.1.7",
"@typescript-eslint/eslint-plugin": "7.1.1",
"@typescript-eslint/parser": "7.1.1",
Expand Down
2 changes: 1 addition & 1 deletion templates/vanilla/packages/contracts/worlds.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"31337": {
"address": "0x4f4ddafbc93cf8d11a253f21ddbcf836139efdec"
"address": "0x8d8b6b8414e1e3dcfd4168561b9be6bd3bf6ec4b"
}
}

0 comments on commit d28ad48

Please sign in to comment.