Skip to content

dfx.jsonに追加ペア(frontend用) #1

@hokosugi

Description

@hokosugi

cloneした Small_NFT を そのまま dfx deploy すると、forontend(index.js等)がdeployされないので、
ペアを追加して以下のようにすると、ローカルでfrontendが表示できるようになったのでご検討ください。
初めてのissueなのでうまく書けなくてごめんなさい!

{
  "canisters": {
    "small_nft": {
      "main": "src/small_nft/main.mo",
      "type": "motoko"
    },
  "small_nft_assets": {
    "dependencies": [
      "small_nft"
    ],
    "frontend": {
      "entrypoint": "src/small_nft_assets/src/index.html"
    },
    "source": [
      "src/small_nft_assets/assets",
      "dist/small_nft_assets/"
    ],
    "type": "assets"
  }
  },
  "defaults": {
    "build": {
      "args": "",
      "packtool": ""
    }
  },
  "dfx": "0.8.1",
  "networks": {
    "local": {
      "bind": "127.0.0.1:8000",
      "type": "ephemeral"
    }
  },
  "version": 1
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions