diff --git a/content/02-new-to-cardano/10-what-is-a-smart-contract.mdx b/content/02-new-to-cardano/10-what-is-a-smart-contract.mdx index 831110a8..211f0511 100644 --- a/content/02-new-to-cardano/10-what-is-a-smart-contract.mdx +++ b/content/02-new-to-cardano/10-what-is-a-smart-contract.mdx @@ -3,24 +3,14 @@ title: What is a smart contract? metaTitle: What is a smart contract? --- -A _smart contract_ is an automated digital agreement, written in code, that -tracks, verifies, and executes the binding transactions of a contract between -various parties. The transactions of the contract are automatically executed by -the smart contract code when predetermined conditions are met. Essentially, a -smart contract is a short program whose inputs and outputs are transactions on a -blockchain. +Smart contracts on Cardano are simple programs often referred to as validator scripts in which users define custom logic. They are automatically executed by each Cardano node validating the transaction when the transaction attempts to move funds from the script's address. The address of each script is derived from the hash-sum of the compiled script. -Smart contracts are self executing and reliable and do not require the actions -or presence of third parties. The smart contract code is stored on, and -distributed across, a decentralised blockchain network, making it transparent -and irreversible. +Once deployed, smart contracts become immutable, which means they cannot be changed. They are distributable and tamper-proof, fast, and cost-effective, as there is no intermediary, which saves both money and time. -In summary, smart contracts are immutable as a contract cannot be changed, they -are distributable and tamper-proof, fast and cost effective, as there is no -middle man which saves money and time, and is safe due to encryption. +## Tooling and languages Cardano introduced smart contract support in 2021. As a multi-functional -environment, Cardano supports the development and deployment of smart +environment, Cardano now supports the development and deployment of smart contracts using such programming languages as: - **Plutus** — a purpose-built smart contract development and execution @@ -33,15 +23,16 @@ contracts using such programming languages as: financial contracts that allows building contracts visually as well as in more traditional code. Financial institutions can use it to develop and deploy custom instruments for their customers and clients, for example. The Marlowe - language itself is now embedded in both JavaScript and Haskell offering a - choice of editors depending on developers’ preference and skillset. - -Currently, there are more smart contract languages and tools to build on Cardano. For more details, see: + language itself is now embedded in JavaScript, TypeScript, and Haskell offering a + choice of editors depending on developers’ preferences and skills. +- - **[Aiken](https://aiken-lang.org/)** - a language and toolchain favoring developer experience. Aiken is used for on-chain validator scripts only. +- - **[OpShin](https://github.com/OpShin)** - a programming language based on Python for generic smart contracts for Cardano. +- **[plu-ts](https://github.com/HarmonicLabs/plu-ts)** - TypeScript-embedded smart contract programming language and a transaction creation library. -- [Plutus tooling](https://docs.cardano.org/plutus/plutus-resources/#plutustooling) -- [A list of community-built developer tools on Cardano](https://www.essentialcardano.io/article/a-list-of-community-built-developer-tools-on-cardano) - -#### Related Topics +### Further reading and related topics +- [Developer Portal - smart contracts overview](https://developers.cardano.org/docs/smart-contracts/) +- [A list of community-built developer tools on Cardano](https://www.essentialcardano.io/article/a-list-of-community-built-developer-tools-on-cardano) +- [Plutus tooling](https://docs.cardano.org/plutus/plutus-resources/#plutustooling) - [Marlowe explainer](/marlowe/learn-about-marlowe) - [Plutus explainer](/plutus/learn-about-plutus) diff --git a/content/12-smart-contracts.mdx b/content/12-smart-contracts.mdx new file mode 100644 index 00000000..341d9ffc --- /dev/null +++ b/content/12-smart-contracts.mdx @@ -0,0 +1,6 @@ +--- +title: Smart Contracts +metaTitle: Smart Contracts +--- + + diff --git a/content/12-plutus.mdx b/content/12-smart-contracts/01-plutus.mdx similarity index 100% rename from content/12-plutus.mdx rename to content/12-smart-contracts/01-plutus.mdx diff --git a/content/12-plutus/01-learn-about-plutus.mdx b/content/12-smart-contracts/01-plutus/01-learn-about-plutus.mdx similarity index 100% rename from content/12-plutus/01-learn-about-plutus.mdx rename to content/12-smart-contracts/01-plutus/01-learn-about-plutus.mdx diff --git a/content/12-plutus/02-plutus-resources.mdx b/content/12-smart-contracts/01-plutus/02-plutus-resources.mdx similarity index 100% rename from content/12-plutus/02-plutus-resources.mdx rename to content/12-smart-contracts/01-plutus/02-plutus-resources.mdx diff --git a/content/12-plutus/03-plutus-scripts.mdx b/content/12-smart-contracts/01-plutus/03-plutus-scripts.mdx similarity index 100% rename from content/12-plutus/03-plutus-scripts.mdx rename to content/12-smart-contracts/01-plutus/03-plutus-scripts.mdx diff --git a/content/12-plutus/04-dapp-development.mdx b/content/12-smart-contracts/01-plutus/04-dapp-development.mdx similarity index 100% rename from content/12-plutus/04-dapp-development.mdx rename to content/12-smart-contracts/01-plutus/04-dapp-development.mdx diff --git a/content/12-plutus/05-Plutus-use-cases.mdx b/content/12-smart-contracts/01-plutus/05-Plutus-use-cases.mdx similarity index 100% rename from content/12-plutus/05-Plutus-use-cases.mdx rename to content/12-smart-contracts/01-plutus/05-Plutus-use-cases.mdx diff --git a/content/12-plutus/06-collateral-mechanism.mdx b/content/12-smart-contracts/01-plutus/06-collateral-mechanism.mdx similarity index 100% rename from content/12-plutus/06-collateral-mechanism.mdx rename to content/12-smart-contracts/01-plutus/06-collateral-mechanism.mdx diff --git a/content/12-plutus/07-transaction-costs-determinism.mdx b/content/12-smart-contracts/01-plutus/07-transaction-costs-determinism.mdx similarity index 100% rename from content/12-plutus/07-transaction-costs-determinism.mdx rename to content/12-smart-contracts/01-plutus/07-transaction-costs-determinism.mdx diff --git a/content/12-plutus/08-sc-best-practices.mdx b/content/12-smart-contracts/01-plutus/08-sc-best-practices.mdx similarity index 100% rename from content/12-plutus/08-sc-best-practices.mdx rename to content/12-smart-contracts/01-plutus/08-sc-best-practices.mdx diff --git a/content/12-plutus/Plutus_arch.png b/content/12-smart-contracts/01-plutus/Plutus_arch.png similarity index 100% rename from content/12-plutus/Plutus_arch.png rename to content/12-smart-contracts/01-plutus/Plutus_arch.png diff --git a/content/13-marlowe.mdx b/content/12-smart-contracts/02-marlowe.mdx similarity index 100% rename from content/13-marlowe.mdx rename to content/12-smart-contracts/02-marlowe.mdx diff --git a/content/13-marlowe/01-learn-about-marlowe.mdx b/content/12-smart-contracts/02-marlowe/01-learn-about-marlowe.mdx similarity index 84% rename from content/13-marlowe/01-learn-about-marlowe.mdx rename to content/12-smart-contracts/02-marlowe/01-learn-about-marlowe.mdx index 568d3c1c..6e02ec9f 100644 --- a/content/13-marlowe/01-learn-about-marlowe.mdx +++ b/content/12-smart-contracts/02-marlowe/01-learn-about-marlowe.mdx @@ -33,3 +33,11 @@ To get started with Marlowe, find the various resources on the updated [document - [Videos](https://docs.marlowe.iohk.io/tutorials/videos) - [Contract gallery](https://docs.marlowe.iohk.io/docs/examples/examples-contract-gallery) - [Developer tools](https://docs.marlowe.iohk.io/docs/developer-tools/overview). + +## Technical specifications and documentation + +|Link|Description| +|----|-----------| +| [Marlowe](https://github.com/input-output-hk/marlowe) | Chain-agnostic Marlowe specification and reference implementation +| [Marlowe Cardano](https://github.com/input-output-hk/marlowe-cardano/) | The Cardano specific implementation of Marlowe +| [Developer Portal](https://developers.cardano.org/docs/smart-contracts/marlowe) | Documentation for introducing Marlowe to developers | diff --git a/content/12-smart-contracts/03-aiken.mdx b/content/12-smart-contracts/03-aiken.mdx new file mode 100644 index 00000000..00296af2 --- /dev/null +++ b/content/12-smart-contracts/03-aiken.mdx @@ -0,0 +1,6 @@ +--- +title: Aiken +metaTitle: Aiken +--- + + diff --git a/content/12-smart-contracts/03-aiken/01-learn-about-aiken.mdx b/content/12-smart-contracts/03-aiken/01-learn-about-aiken.mdx new file mode 100644 index 00000000..911ac952 --- /dev/null +++ b/content/12-smart-contracts/03-aiken/01-learn-about-aiken.mdx @@ -0,0 +1,24 @@ +--- +title: Learn about Aiken +metaTitle: Learn about Aiken +--- + +> ⚠️ Please note that Aiken is still in development and is not yet recommended for use in production environments. + +Aiken is a new programming language and toolchain for developing smart contracts on the Cardano blockchain. It draws inspiration from various modern languages, like Gleam, Rust, and Elm, renowned for their friendly error messages and an overall excellent developer experience. + +The language is exclusively used for creating on-chain validator scripts. Users will need to write their off-chain code for generating transactions in another language, such as Rust, Haskell, JavaScript, Python, etc. + +As a language, Aiken is purely functional with static typing and type inference. This means most of the time, the compiler is smart enough to determine the type of something without requiring user annotation. It also allows the creation of custom types resembling records and enums. Aiken does not include higher-kinded types or type classes because it aims for simplicity. + +On-chain scripts are typically small in size and scope compared to other kinds of applications being developed today. Consequently, they do not necessitate as many features as general-purpose languages that must tackle far more complex issues. + +Aiken is easier than Plutus to get started with for those who are less familiar with functional languages like Haskell. Similar to Plutus, Aiken scripts are compiled down to the untyped Plutus Core (UPLC). + +## Resources + +- [Aiken website](https://aiken-lang.org) +- [GitHub repository](https://github.com/aiken-lang/aiken) + + + diff --git a/content/14-community.mdx b/content/13-community.mdx similarity index 100% rename from content/14-community.mdx rename to content/13-community.mdx diff --git a/content/14-community/01-cips.mdx b/content/13-community/01-cips.mdx similarity index 100% rename from content/14-community/01-cips.mdx rename to content/13-community/01-cips.mdx diff --git a/content/14-community/02-essential-cardano.mdx b/content/13-community/02-essential-cardano.mdx similarity index 100% rename from content/14-community/02-essential-cardano.mdx rename to content/13-community/02-essential-cardano.mdx diff --git a/content/14-community/03-community-content.mdx b/content/13-community/03-community-content.mdx similarity index 100% rename from content/14-community/03-community-content.mdx rename to content/13-community/03-community-content.mdx diff --git a/content/14-community/04-Cardano-stack-exchange.mdx b/content/13-community/04-Cardano-stack-exchange.mdx similarity index 100% rename from content/14-community/04-Cardano-stack-exchange.mdx rename to content/13-community/04-Cardano-stack-exchange.mdx diff --git a/content/14-community/05-ambassador-program.mdx b/content/13-community/05-ambassador-program.mdx similarity index 100% rename from content/14-community/05-ambassador-program.mdx rename to content/13-community/05-ambassador-program.mdx diff --git a/content/14-community/06-getting-support.mdx b/content/13-community/06-getting-support.mdx similarity index 100% rename from content/14-community/06-getting-support.mdx rename to content/13-community/06-getting-support.mdx diff --git a/content/15-pioneer-programs.mdx b/content/14-pioneer-programs.mdx similarity index 100% rename from content/15-pioneer-programs.mdx rename to content/14-pioneer-programs.mdx diff --git a/content/15-pioneer-programs/01-plutus-pioneers.mdx b/content/14-pioneer-programs/01-plutus-pioneers.mdx similarity index 100% rename from content/15-pioneer-programs/01-plutus-pioneers.mdx rename to content/14-pioneer-programs/01-plutus-pioneers.mdx diff --git a/content/15-pioneer-programs/02-marlowe-pioneers.mdx b/content/14-pioneer-programs/02-marlowe-pioneers.mdx similarity index 100% rename from content/15-pioneer-programs/02-marlowe-pioneers.mdx rename to content/14-pioneer-programs/02-marlowe-pioneers.mdx diff --git a/content/16-tools.mdx b/content/15-tools.mdx similarity index 100% rename from content/16-tools.mdx rename to content/15-tools.mdx diff --git a/content/16-tools/02-release-notes.mdx b/content/15-tools/02-release-notes.mdx similarity index 100% rename from content/16-tools/02-release-notes.mdx rename to content/15-tools/02-release-notes.mdx diff --git a/content/16-tools/03-comp-matrix.mdx b/content/15-tools/03-comp-matrix.mdx similarity index 100% rename from content/16-tools/03-comp-matrix.mdx rename to content/15-tools/03-comp-matrix.mdx diff --git a/content/16-tools/Cardano component dependencies 072021.png b/content/15-tools/Cardano component dependencies 072021.png similarity index 100% rename from content/16-tools/Cardano component dependencies 072021.png rename to content/15-tools/Cardano component dependencies 072021.png diff --git a/content/16-tools/Cardano_component_dependencies.png b/content/15-tools/Cardano_component_dependencies.png similarity index 100% rename from content/16-tools/Cardano_component_dependencies.png rename to content/15-tools/Cardano_component_dependencies.png diff --git a/content/16-tools/comp-dependencies-new.png b/content/15-tools/comp-dependencies-new.png similarity index 100% rename from content/16-tools/comp-dependencies-new.png rename to content/15-tools/comp-dependencies-new.png diff --git a/netlify.toml b/netlify.toml index c36b9938..1ec30a09 100644 --- a/netlify.toml +++ b/netlify.toml @@ -659,17 +659,17 @@ status = 301 [[redirects]] from = "https://testnets.cardano.org/programming-languages/plutus/overview/" - to = "/plutus/learn-about-plutus" + to = "/smart-contracts/plutus/learn-about-plutus" status = 301 [[redirects]] from = "https://testnets.cardano.org/programming-languages/plutus/getting-started/" - to = "/plutus/Plutus-PG-setup" + to = "/smart-contracts/plutus/Plutus-PG-setup" status = 301 [[redirects]] from = "https://testnets.cardano.org/programming-languages/plutus/resources/" - to = "/plutus/plutus-resources" + to = "/smart-contracts/plutus/plutus-resources" status = 301 [[redirects]]