Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[draft] ICP Dev Docs Restructure, Overhaul & Audit #3970

Draft
wants to merge 58 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from 18 commits
Commits
Show all changes
58 commits
Select commit Hold shift + click to select a range
259edcc
init
jessiemongeon1 Jan 6, 2025
9c04ea1
building dapps
jessiemongeon1 Jan 8, 2025
6451290
rosetta
jessiemongeon1 Jan 8, 2025
0d1aeb9
references
jessiemongeon1 Jan 8, 2025
0b5d9db
references
jessiemongeon1 Jan 9, 2025
10bbe23
Finish redirects and link updates
jessiemongeon1 Jan 9, 2025
e4e2034
content revisions
jessiemongeon1 Jan 10, 2025
d7c4e57
audit dev education, getting started, dev tools sections
jessiemongeon1 Jan 10, 2025
3243e2b
interacting, launching, managing dapps
jessiemongeon1 Jan 13, 2025
79ff84c
network features and chain fusion
jessiemongeon1 Jan 14, 2025
e773c79
sns, tokens, rosetta
jessiemongeon1 Jan 15, 2025
7a9151c
tutorials
jessiemongeon1 Jan 16, 2025
f61808d
references
jessiemongeon1 Jan 16, 2025
b7cee04
Check all links; add dev education pages
jessiemongeon1 Jan 17, 2025
96b0a85
link checks, applying feedback, formatting
jessiemongeon1 Jan 21, 2025
f32f788
link checks, applying feedback, formatting
jessiemongeon1 Jan 21, 2025
e89582d
finish link checks and format fixes
jessiemongeon1 Jan 22, 2025
dff3ecb
merge conflicts
jessiemongeon1 Jan 22, 2025
0539633
Apply suggestions from code review
jessiemongeon1 Jan 22, 2025
e8ab8a3
fix conflicts
jessiemongeon1 Jan 22, 2025
3971426
fix conflicts
jessiemongeon1 Jan 22, 2025
37a07ca
fix conflicts
jessiemongeon1 Jan 22, 2025
b799df8
Delete blog/news-and-updates/2025-01-22-update.mdx
jessiemongeon1 Jan 22, 2025
aa2033c
fix redirects
jessiemongeon1 Jan 22, 2025
29140bb
Merge branch 'jmongeon-docs-restructure' of github.com:dfinity/portal…
jessiemongeon1 Jan 22, 2025
99e1c5f
fix redirects
jessiemongeon1 Jan 22, 2025
fd2289e
fix redirects
jessiemongeon1 Jan 22, 2025
5bdc3b7
fix redirects
jessiemongeon1 Jan 22, 2025
dde9107
fix redirects
jessiemongeon1 Jan 23, 2025
92c7d7d
fix redirects
jessiemongeon1 Jan 23, 2025
985a82f
fix redirects
jessiemongeon1 Jan 23, 2025
7978512
Update sidebars.js
jessiemongeon1 Jan 23, 2025
f886929
Update first-smart-contract.mdx
jessiemongeon1 Jan 23, 2025
88e599e
Update sidebars.js
jessiemongeon1 Jan 23, 2025
0c8c484
Update sidebars.js
jessiemongeon1 Jan 23, 2025
445e50a
Update sidebars.js
jessiemongeon1 Jan 23, 2025
2b61c95
misc
jessiemongeon1 Jan 23, 2025
b133047
misc
jessiemongeon1 Jan 23, 2025
e6ac5a3
misc
jessiemongeon1 Jan 23, 2025
b4be0d2
misc
jessiemongeon1 Jan 23, 2025
1fe9074
misc
jessiemongeon1 Jan 23, 2025
43afd18
update file paths
jessiemongeon1 Jan 27, 2025
4ba1caa
structure v2
jessiemongeon1 Jan 28, 2025
40c02a8
Merge branch 'master' into jmongeon-docs-restructure
jessiemongeon1 Jan 28, 2025
72750b1
structure v2
jessiemongeon1 Jan 28, 2025
d96574b
structure v2
jessiemongeon1 Jan 28, 2025
6748482
fix redirects
jessiemongeon1 Jan 28, 2025
6624766
fix redirects
jessiemongeon1 Jan 28, 2025
c867e6a
fix redirects
jessiemongeon1 Jan 28, 2025
5c8bc7a
fix redirects
jessiemongeon1 Jan 28, 2025
4a75055
fix redirects
jessiemongeon1 Jan 28, 2025
7f4ca9a
fix redirects
jessiemongeon1 Jan 28, 2025
22a71cf
fix redirects
jessiemongeon1 Jan 29, 2025
7d7c6d1
Update subs
jessiemongeon1 Jan 29, 2025
72ec2e3
Update subs
jessiemongeon1 Jan 29, 2025
1bb3f77
Update subs
jessiemongeon1 Jan 29, 2025
2445c10
Update subs
jessiemongeon1 Jan 29, 2025
41f6a41
Dev Weekly Update Jan 29
jessiemongeon1 Jan 29, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
24 changes: 12 additions & 12 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
.github/ @dfinity/idx
* @dfinity/editorial

docs/developer-docs/updates/release-notes/ @dfinity/dx
docs/developer-docs/build/agents @dfinity/dx
docs/developer-docs/build/cdks @dfinity/dx
docs/developer-docs/integrations/rosetta @dfinity/finint
docs/developer-docs/security @dfinity/product-security
docs/other/updates/release-notes/ @dfinity/dx
docs/building-dapps/interacting-with-dapps/agents/overview @dfinity/dx
docs/building-dapps/developer-tools/cdks/index @dfinity/dx
docs/rosetta-defi/ @dfinity/finint
docs/developer-education/security @dfinity/product-security
docs/references/execution-errors.mdx @dfinity/execution
docs/references/ingress-messages.mdx @dfinity/product-security
docs/references/message-execution-properties.mdx @dfinity/product-security
docs/developer-docs/web-apps/custom-domains @dfinity/boundary-node
docs/developer-docs/web-apps/http-compatible-canisters @dfinity/trust
docs/developer-education/message-execution/ingress-messages.mdx @dfinity/product-security
docs/developer-education/message-execution/message-execution-properties.mdx @dfinity/product-security
docs/building-dapps/dapp-frontends/custom-domains/ @dfinity/boundary-node
docs/building-dapps/using-network-features/using-external-data/http-gateways-certification/ @dfinity/trust
jessiemongeon1 marked this conversation as resolved.
Show resolved Hide resolved

# Each piece of documentation must be owned by the respective teams
docs/developer-docssmart-contracts/advanced-features/simd.mdx @dfinity/execution
docs/developer-docssmart-contracts/advanced-features/periodic-tasks.mdx @dfinity/execution
docs/developer-docs/smart-contracts/best-practices/idempotency.mdx @dfinity/research @dfinity/product-security
docs/building-dapps/using-network-features/simd.mdx @dfinity/execution
docs/building-dapps/using-network-features/periodic-tasks-timers.mdx @dfinity/execution
docs/developer-education/developer-playbook/developer-best-practices/idempotency.mdx @dfinity/research @dfinity/product-security

# The Interface Specification
docs/references/_attachments/certificates.cddl @dfinity/canister-os
Expand Down
5 changes: 4 additions & 1 deletion .github/workflows/docs-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@ on:
issue_comment:
types: [created]
paths:
- docs/developer-docs/
- docs/developer-education
- docs/building-dapps
- docs/rosetta-defi
- docs/references

jobs:
check_comment:
Expand Down
6 changes: 5 additions & 1 deletion .github/workflows/docs-tag.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,11 @@ name: Tag Docs PRs
on:
pull_request:
paths:
- docs/developer-docs/**
- docs/developer-education/**
- docs/building-dapps/**
- docs/rosetta-defi/**
- docs/tutorials/**

jobs:
docs-tag:
name: Tag PR with documentation
Expand Down
17 changes: 8 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -371,18 +371,18 @@ Failing to do so will break the code that auto-populates the Tooltip with the ap

The developer docs utilize submodules for several subfolders of documentation. To edit these pages, changes must be made in the submodule's repo and merged into that repo. Then you must open a PR in this repo that pulls the latest submodule updates to apply the changes.

The following submoules and their corresponding repos are currently used:
The following submodules and their corresponding repos are currently used:

- SDK
- `/docs/current/developer-docs/developer-tools/cli-tools/cli-reference/`
- `/docs/current/building-dapps/developer-tools/dfx/`
- GitHub Repo: https://github.com/dfinity/sdk.git

- Motoko
- `/docs/current/motoko/main/base/`
- GitHub Repo: https://github.com/dfinity/motoko.git

- quill
- `/docs/current/developer-docs/developer-tools/cli-tools/quill`
- `/docs/current/building-dapps/developer-tools/quill`
- GitHub Repo: https://github.com/dfinity/quill.git

- Internet Identity
Expand All @@ -395,11 +395,11 @@ The following submoules and their corresponding repos are currently used:
- Note: This submodule intentionally uses `.md` files instead of `.mdx` files. Therefore, these pages do not support components such as tags and tooltips.

- dfxvm
- `/docs/current/developer-docs/developer-tools/cli-tools/dfxvm/docs/cli-reference/dfx/`
- `/docs/current/building-dapps/developer-tools/dfxvm/dfx/`
- GitHub Repo: https://github.com/dfinity/dfxvm.git

- Response verification
- `/docs/current/developer-docs/web-apps/http-compatible-canisters/custom-http-canisters`
- `/docs/current/building-dapps/using-network-features/using-external-data/http-gateways-certification/`
- GitHub Repo: https://github.com/dfinity/response-verification

### Updating submodules
Expand Down Expand Up @@ -538,14 +538,13 @@ The `.subpage.md` files will each generate a subpage under `/how-it-works/`, bas

## Adding documentation for community-created agents and CDKs

The [agents](https://internetcomputer.org/docs/current/developer-docs/build/agents)
and [CDKs](https://internetcomputer.org/docs/current/developer-docs/build/cdks) sections should not only contain docs
The [agents](/docs/current/building-dapps/interacting-with-dapps/agents/overview)
and [CDKs](/docs/current/building-dapps/developer-tools/cdks/index) sections should not only contain docs
for DFINITY-created agents and CDKs.
We therefore invite other projects to:

- Link to their own agents or CDKs on the respective index pages (the files to be edited are
in `docs/developer-docs/build/agents/index.md` or `docs/developer-docs/smart-contracts/write/overview.mdx`).
- Add their own documentation as a folder under `Agents` or `CDKs`.
in `/docs/current/building-dapps/interacting-with-dapps/agents/overview` or `/docs/building-dapps/developer-tools/cdks/index.md`).

## Adding community-created developer tools

Expand Down
6 changes: 3 additions & 3 deletions blog/features/async-performance-counter.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ image: /img/blog/async-performance-counter.webp

The Internet Computer can host a full dapp — frontend, backend and data. Users can deploy their dapp as a canister (smart contract) on the Internet Computer. Each canister can store up to 500GiB of data and execute up to 40 Billion WebAssembly instructions per transaction.

Unlike other blockchains, the Internet Computer offers developers [enormous amounts of resources](/docs/current/developer-docs/smart-contracts/maintain/resource-limits). This poses a real challenge for canister developers: writing efficient canister code. The more efficient a canister is, the less cycles it pays.
Unlike other blockchains, the Internet Computer offers developers [enormous amounts of resources](/docs/current/building-dapps/launching-a-dapp/resource-limits). This poses a real challenge for canister developers: writing efficient canister code. The more efficient a canister is, the less cycles it pays.

Performance counter is the way for a canister (smart contract) to track the amount of work done. This information could be used as the main metric to optimize the code.

Expand Down Expand Up @@ -113,7 +113,7 @@ But in this case there is no need to instrument every single await point in the

## Using performance counters

To quickly run the performance counters example (assuming the Internet Computer SDK is [already installed](/docs/current/developer-docs/getting-started/install)):
To quickly run the performance counters example (assuming the Internet Computer SDK is [already installed](/docs/current/building-dapps/getting-started/install)):

```
$ git clone [email protected]:dfinity/examples.git
Expand Down Expand Up @@ -143,6 +143,6 @@ Python: from kybra import ic

## References

- Backend developers guide: [Optimizing Rust canisters](/docs/current/developer-docs/backend/rust/optimizing).
- Backend developers guide: [Optimizing Rust canisters](/docs/current/building-dapps/developer-tools/cdks/rust/optimizing).

- Motoko developers guide: [Optimizing canisters](/docs/current/motoko/main/getting-started/motoko-introduction).
2 changes: 1 addition & 1 deletion blog/features/composite-query.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ The complete code can be found [here](https://github.com/dfinity/examples/tree/m
An alternative implementation for Motoko can be found [here](https://github.com/dfinity/examples/tree/master/motoko/composite_query).

## Using composite queries
To start, let's set up our development environment. Make sure you have [dfx](/docs/current/developer-docs/getting-started/install) installed on your computer. You will need at least version 0.15.0 of dfx for composite query support. Open your terminal and follow these commands:
To start, let's set up our development environment. Make sure you have [dfx](/docs/current/building-dapps/getting-started/install) installed on your computer. You will need at least version 0.15.0 of dfx for composite query support. Open your terminal and follow these commands:

```bash
DFX_VERSION=0.15.0-beta.1 sh -ci "$(curl -fsSL https://internetcomputer.org/install.sh)"
Expand Down
2 changes: 1 addition & 1 deletion blog/features/deprecating-the-service-worker.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ Presently, there are three distinct implementations of this protocol: the Servic

### The Service Worker

The Service Worker operates on `{canisterId}.ic0.app` and `{canisterId}.icp0.io` URLs as well as [Boundary Node hosted custom domains](/docs/current/developer-docs/web-apps/custom-domains/using-custom-domains). For example, Internet Identity can be accessed via the Service Worker using the following URLs:
The Service Worker operates on `{canisterId}.ic0.app` and `{canisterId}.icp0.io` URLs as well as [Boundary Node hosted custom domains](/docs/current/building-dapps/dapp-frontends/custom-domains/using-custom-domains). For example, Internet Identity can be accessed via the Service Worker using the following URLs:

- [rdmx6-jaaaa-aaaaa-aaadq-cai.ic0.app](https://rdmx6-jaaaa-aaaaa-aaadq-cai.ic0.app/)
- [rdmx6-jaaaa-aaaaa-aaadq-cai.icp0.io](https://rdmx6-jaaaa-aaaaa-aaadq-cai.icp0.io/)
Expand Down
2 changes: 1 addition & 1 deletion blog/features/dfx-deps.md
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ After this step, the pulled dependencies can be deployed on a local replica usin

## Conclusion

The `dfx deps` feature is available in dfx versions `0.14.1` and newer. You can learn more from our [developer documentation](/docs/current/developer-docs/smart-contracts/maintain/import), which includes an interactive example you can use to test the feature for yourself.
The `dfx deps` feature is available in dfx versions `0.14.1` and newer. You can learn more from our [developer documentation](/docs/current/building-dapps/interacting-with-dapps/using-third-party-canisters), which includes an interactive example you can use to test the feature for yourself.

As always, please let us know if you have any feedback either through our [forum](https://forum.dfinity.org/) or [Discord server](https://discord.com/invite/5PJMmmETQB).

Expand Down
4 changes: 2 additions & 2 deletions blog/features/evm-rpc-canister-launch.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ or submitting feedback on the

<a
className={"button button-primary"}
href={"https://internetcomputer.org/docs/current/developer-docs/multi-chain/ethereum/evm-rpc/evm-rpc-canister"}
href={"https://internetcomputer.org/docs/current/building-dapps/chain-fusion/ethereum/evm-rpc/evm-rpc-canister"}
>
View the documentation
</a>
Expand Down Expand Up @@ -116,7 +116,7 @@ hopefully it still shows you how easy it is to get started.

<!-- prettier-ignore-start -->
:::info
Please ensure you [install](/docs/current/developer-docs/getting-started/install) `dfx` before proceeding with the steps below.
Please ensure you [install](/docs/current/building-dapps/getting-started/install) `dfx` before proceeding with the steps below.
:::
<!-- prettier-ignore-end -->

Expand Down
8 changes: 4 additions & 4 deletions blog/features/motoko-dev-server.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,13 +63,13 @@ Once you’ve installed the tool, run `mo-dev --help` to view usage examples and

## Candid UI

Let’s say you’re developing a Motoko smart contract using the [Candid UI](/docs/current/developer-docs/smart-contracts/candid/candid-concepts). Here’s a command which will redeploy the canister on file change:
Let’s say you’re developing a Motoko smart contract using the [Candid UI](/docs/current/building-dapps/interacting-with-dapps/candid/candid-concepts). Here’s a command which will redeploy the canister on file change:

```sh
mo-dev --deploy -y
```

The `-y` flag automatically responds “yes” to prompts from [dfx](/docs/current/developer-docs/developer-tools/cli-tools/cli-reference/dfx-deploy) about upgrading the canister interface (potentially clearing canister data). Feel free to include or omit this depending on your use case.
The `-y` flag automatically responds “yes” to prompts from [dfx](/docs/current/building-dapps/developer-tools/dfx/dfx-deploy) about upgrading the canister interface (potentially clearing canister data). Feel free to include or omit this depending on your use case.

## Full-Stack Dapp

Expand Down Expand Up @@ -100,7 +100,7 @@ With this project configuration, `npm start` will run the Vite and Motoko dev se

Another benefit of this configuration is that anyone can run the dev server without needing to globally install the `mo-dev` command, which is great for encouraging open-source contributions or working as part of a team.

This project configuration will be included by default in the upcoming changes to the [dfx new](/docs/current/developer-docs/developer-tools/cli-tools/cli-reference/dfx-new) command.
This project configuration will be included by default in the upcoming changes to the [dfx new](/docs/current/building-dapps/developer-tools/dfx/dfx-new) command.

`mo-dev` ships with a test runner compatible with third-party libraries such as motoko-matchers.

Expand Down Expand Up @@ -163,7 +163,7 @@ CI=true mo-dev --generate --deploy
Here are a few miscellaneous tips which might come in handy while working with `mo-dev`:

* Live reloading works when switching Git branches, which is useful to keep in mind for code reviews and pair programming.
* If you’ve used [dfx generate](/docs/current/developer-docs/developer-tools/cli-tools/cli-reference/dfx-generate), you might have encountered a common catch-22 where both `dfx generate` and `dfx deploy` require running each other first. `mo-dev --generate --deploy` automatically handles this situation for you.
* If you’ve used [dfx generate](/docs/current/building-dapps/developer-tools/dfx/dfx-generate), you might have encountered a common catch-22 where both `dfx generate` and `dfx deploy` require running each other first. `mo-dev --generate --deploy` automatically handles this situation for you.
* You can define custom live-reload logic using `mo-dev --exec <command>`.

---
Expand Down
2 changes: 1 addition & 1 deletion blog/features/node-metrics.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ image: /img/blog/node-metrics.webp

[The Internet Computer protocol](https://internetcomputer.org/) coordinates the creation and interaction of subnet blockchains created by standardized node machines run by independent owners and installed within independent data centers around the globe to ensure decentralization. Compared to other blockchains, the Internet Computer has stronger requirements on the performance and availability of the nodes. This is due to the fact that most of the node resources are dedicated to [performing useful work](https://wiki.internetcomputer.org/wiki/Proof_of_Useful_Work) such as executing smart contracts and participating in threshold cryptography — tasks that needs to be performed by all nodes of a given subnet blockchain, and at a much lower replication factor than other blockchains, for energy and cost efficiency.

The Internet Computer is designed in a way that allows anyone to become a [node provider (NP)](https://internetcomputer.org/node-providers). In a decentralized manner, each node provider is verified and voted in by token holders via the [Network Nervous System (NNS)](/docs/current/developer-docs/daos/nns/overview), the DAO that governs the Internet Computer. The NNS acts as a decentralized algorithmic authority that oversees the network’s operations and evolution, including scaling the Internet Computer’s capacity by adding more nodes. In this regard, it makes sense to be able to measure node contributions and allow their providers to diagnose node problems efficiently. With trustworthy node metrics, the [node provider remuneration model](https://wiki.internetcomputer.org/wiki/Node_Provider_Remuneration) can be adjusted to reward precise node contributions, rather than a fixed monthly sum to cover hardware and operational costs.
The Internet Computer is designed in a way that allows anyone to become a [node provider (NP)](https://internetcomputer.org/node-providers). In a decentralized manner, each node provider is verified and voted in by token holders via the [Network Nervous System (NNS)](/docs/current/move-to-learnhub/nns/overview), the DAO that governs the Internet Computer. The NNS acts as a decentralized algorithmic authority that oversees the network’s operations and evolution, including scaling the Internet Computer’s capacity by adding more nodes. In this regard, it makes sense to be able to measure node contributions and allow their providers to diagnose node problems efficiently. With trustworthy node metrics, the [node provider remuneration model](https://wiki.internetcomputer.org/wiki/Node_Provider_Remuneration) can be adjusted to reward precise node contributions, rather than a fixed monthly sum to cover hardware and operational costs.

## Trustworthy metrics

Expand Down
8 changes: 4 additions & 4 deletions blog/news-and-updates/2023-01-23-update.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ It’s a light week this week from the languages team!
![Header image](../_assets/motoko-cubed.png)

There are currently discussions about what the future of Motoko package management looks like with respect to Vessel and
other package management tools that the community is using, such as [MOPS](https://mops.one/). There was a nice post by
other package management tools that the community is using, such as [Mops](https://mops.one/). There was a nice post by
@icme recently talking about this issue that can be found
here: https://forum.dfinity.org/t/developer-feedback-opportunity-motoko-package-manager-improvements-redesign/18137

Expand Down Expand Up @@ -68,7 +68,7 @@ let x = do {
This is also how you can bind to an `if` expression.

```
let x =
let x =
if (y < 0) {
foo();
2
Expand All @@ -83,7 +83,7 @@ You can even bind a variable to a `while` loop, but that is less useful, because
the type system to always evaluate to unit.

```
let x =
let x =
while (y < 0) {
foo();
};
Expand All @@ -105,7 +105,7 @@ You can also add a `?` to the `do` block to work with option types.

```
let x : ?Nat = foo(); // x is an option type who may or may not be null
let y =
let y =
do ? {
x! + 3
};
Expand Down
2 changes: 1 addition & 1 deletion blog/news-and-updates/2023-01-30-update.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ canisters’ performance and informs you on how you can fine tune your code to a

There’s a new kid on the block - @rvanasa just released a new JavaScript library for interacting with Internet Computer.
From the repository description,
The ic0 package is a simple, straightforward way to interact with canisters running on the Internet Computer (ICP).
The ic0 package is a simple, straightforward way to interact with canisters running on the Internet Computer.
With ic0 you can instantiate representations of local, dev, or ICP canisters in JS, make calls to them, and evaluate
their responses. You can also create mock canisters for testing or running experiments.
Give it a try and let us know what you think.
Expand Down
Loading
Loading