@4cadia/janus-indexer-smartcontract 中文文档教程

发布于 5年前 浏览 30 更新于 3年前

Janus Indexer Smart Contrat

该智能合约被指定为前端和 janusndxr 提供指令,以对 Janus 平台上的内容进行索引,并在被要求搜索它们时提供信息。


Prerequisites

  • truffle
  • ganache cli


Featured Technologies

Solidty: 是一种面向对象的编程语言,用于编写智能合约。 它用于在各种区块链平台上实施智能合约,最著名的是以太坊。

智能合约:是一种计算机协议,旨在以数字方式促进、验证或强制执行合同的谈判或履行。

Truffle 迁移(部署):迁移是 JavaScript 文件,可帮助您将合约部署到以太坊网络。 这些文件负责暂存您的部署任务,它们是在您的部署需求会随时间变化的假设下编写的。 随着项目的发展,您将创建新的迁移脚本以进一步推动区块链的发展。

Ganache-dev: 是用于以太坊开发的个人区块链,可用于部署合约、开发应用程序和运行测试。

Truffle 测试:是一种自动化测试框架,可让您轻松测试合约。 该框架允许您以两种不同的方式编写简单且易于管理的测试:

- 在 Javascript 和 TypeScript 中,用于从外部世界执行您的合同,就像您的应用程序一样。

-在 Solidity 中,用于在高级、裸机场景中执行您的合约。

Postdeploy: Postdeploy 负责提取构建生成的信息以创建 contract.json 文件


Contributing

  1. Fork it (https://github.com/4cadia/janus.webapp.indexer/fork)
  2. Create your feature branch (git checkout -b feature/fooBar)
  3. Commit your changes (git commit -am 'Add some fooBar')
  4. Push to the branch (git push origin feature/fooBar)
  5. Create a new Pull Request

Janus Indexer Smart Contrat

This Smart Contract is assigned to provide instructions for the Front-end and the janusndxr to do the indexation of a content on the Janus Platform and to provide the information when asked to search for them.


Prerequisites

  • truffle
  • ganache cli


Featured Technologies

Solidty: Is an object-oriented programming language for writing smart contracts. It is used for implementing smart contracts on various blockchain platforms, most notably, Ethereum.

Smart Contract: Is a computer protocol intended to digitally facilitate, verify, or enforce the negotiation or performance of a contract.

Truffle migrate (Deploy): Migrations are JavaScript files that help you deploy contracts to the Ethereum network. These files are responsible for staging your deployment tasks, and they're written under the assumption that your deployment needs will change over time. As your project evolves, you'll create new migration scripts to further this evolution on the blockchain.

Ganache-dev: Is a personal blockchain for Ethereum development you can use to deploy contracts, develop your applications, and run tests.

Truffle test: Is an automated testing framework to make testing your contracts a breeze. This framework lets you write simple and manageable tests in two different ways:

-In Javascript and TypeScript, for exercising your contracts from the outside world, just like your application.

-In Solidity, for exercising your contracts in advanced, bare-to-the-metal scenarios.

Postdeploy: Postdeploy is responsible for extracting build-generated information to create a contract.json file


Contributing

  1. Fork it (https://github.com/4cadia/janus.webapp.indexer/fork)
  2. Create your feature branch (git checkout -b feature/fooBar)
  3. Commit your changes (git commit -am 'Add some fooBar')
  4. Push to the branch (git push origin feature/fooBar)
  5. Create a new Pull Request
    我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
    原文