This is a development platform to quickly generate, develop & deploy smart contract based applications on StarkNet.

Overview

NPM version Downloads generator-starknet-ci Actions Status License sonar-quality-gatesonar-bugs sonar-vulnerabilities

follow on Twitter

generator-starknet

This is a development platform to quickly generate, develop, & deploy smart contract based apps on StarkNet.

StarkNet Generator Demo

Installation

First, install Yeoman and generator-starknet using npm (we assume you have pre-installed node.js).
Make sure you are using a python 3.7.

With NPM:

npm install -g yo
npm install -g generator-starknet

With Yarn:

yarn global add yo
yarn global add generator-starknet

Then generate your new project:

yo starknet

Now follow what is written in the console

License

MIT © Only Dust

Comments
  • Generate protostar based project.

    Generate protostar based project.

    Description

    Currently the generator only supports the generation of nile based projects. As a user, I want to generate a protostar based project.

    Acceptance criteria

    • setup of the generated project should work following generated readme instructions
    • generated projects can be compiled directly after generation
    • generated projects can be tested (unit tests) directly after generation
    Type: feature Context: isolated Duration: few days State: open Difficulty: easy Techno: python Techno: js 
    opened by abdelhamidbakhta 4
  • Error: Trying to copy from a source that does not exist

    Error: Trying to copy from a source that does not exist

    Installed the package using npm. With any version of the package, after going through the options, the following error occurs:

    Error starknet 
    
    Trying to copy from a source that does not exist: /Users/<username>/.nvm/versions/node/v16.13.1/lib/node_modules/generator-starknet/generators/app/templates/.gitignore
    

    This looks like a packaging issue for the .gitignore file in the template. The file appears as .npmignore rather than .gitignore in the node modules.

    Possible solutions may be to do something with .npmignore or just change the template file name to something else, then change it to .gitignore while generating the actual project.

    opened by ericglau 3
  • Generate deployment scripts for Nile

    Generate deployment scripts for Nile

    Description

    As a developer, I would like to have deploy scripts generated for my project.

    The deployment is an important part of the development lifecycle, hence it would improve the dev UX if the generator could prepare deployment scripts.

    Acceptance criteria

    • A new confirm choice is proposed to the user to choose whether or not to generate the deployment scripts
    • Deployment scripts are generated and working with Nile
    Type: feature Difficulty: intermediate Duration: few days Context: coupled State: open Techno: python Techno: js 
    opened by abdelhamidbakhta 2
  • Generate hardhat based project.

    Generate hardhat based project.

    Description

    Currently the generator only supports the generation of nile based projects. As a user, I want to generate a hardhat based project.

    Acceptance criteria

    • setup of the generated project should work following generated readme instructions
    • generated projects can be compiled directly after generation
    • generated projects can be tested (unit tests) directly after generation
    Type: feature 
    opened by abdelhamidbakhta 2
  • Continuous integration

    Continuous integration

    Add a CI workflow that uses the generator to create a new project. Uses all the default choices, and then tests that the project is correctly generated.

    Currently, the project is not generated at all, so you might want to check the generator for a potential bug until this workflow passes.

    opened by Bernardstanislas 2
  • Improve generated tests for customized contracts

    Improve generated tests for customized contracts

    Improve generated tests for customized ERC20/ERC721 contracts to be at parity with default contracts.

    Currently tests for default contracts have a lot more test cases compared to customized contracts (which only test for contract name).

    opened by ericglau 1
  • Generate deployment scripts for Hardhat

    Generate deployment scripts for Hardhat

    Description

    As a developer, I would like to have deploy scripts generated for my project.

    The deployment is an important part of the development lifecycle, hence it would improve the dev UX if the generator could prepare deployment scripts.

    Acceptance criteria

    • A new confirm choice is proposed to the user to choose whether or not to generate the deployment scripts
    • Deployment scripts are generated and working with Hardhat
    Type: feature Difficulty: intermediate Duration: few days Context: coupled State: open Techno: js 
    opened by abdelhamidbakhta 1
  • Use OpenZeppelin Contracts Wizard API to customize ERC20/721

    Use OpenZeppelin Contracts Wizard API to customize ERC20/721

    This integrates the OpenZeppelin Contracts Wizard as the backend for building customized ERC20 and ERC721 contracts with user-selected features.

    If the user chooses to customize their ERC20 or ERC721 contracts, they can enter contract parameters and enable/disable specific features (or accept the defaults for each parameter or feature).

    Example: Screen Shot 2022-05-13 at 12 37 39 PM


    Pull request details:

    • Depends on @openzeppelin/wizard-cairo
    • Includes templated tests for Nile and Hardhat that are customized to pass in the proper parameters for contract construction or initialization.
    • Supports upgradeable contracts and associated proxy deployment in Nile and Hardhat tests.
    opened by ericglau 1
  • Fix CI errors

    Fix CI errors

    Fixes https://github.com/onlydustxyz/generator-starknet/issues/7.

    The extension of generators/app/templates/Nile/README.md was incorrect (.MD instead .md), causing an error when yeoman tried to copy the file. With the correct extension, there was another error: the copied README.md file collided with the project's root README.md file. For this reason, I've updated the test to generate the project in a tmp folder.

    Few things to consider:

    • what's the goal of this test? is it to test the changes made in a commit (in which case linking the local package makes sense, as it's done in this PR), or is it to test the package published on npm only? (in which case it doesn't make much sense to run it on every push)
    • in __tests__/generator.exp, interact was hiding the errors. Was there a good reason to use interact instead of expect eof? Is there any sensitive info that must be hidden?

    PS: you can see that the CI passes now -> https://github.com/yhuard/generator-starknet/runs/6281068442?check_suite_focus=true PPS: I don't know which version of npm you're using, but [email protected] complains about the package-lock.json and wants to update it: npm WARN old lockfile The package-lock.json file was created with an old version of npm ;-)

    opened by yhuard 1
  • Hardhat scripts

    Hardhat scripts

    When generating a Hardhat project, now there is a scripts folder containing files for deployment. The deployment process is the same as the one used in the tests.

    opened by tiagofneto 0
  • Library project mode

    Library project mode

    Add the library mode requested in issue 6.

    The code adds a prompt to ask the developer if he wants this project to be a library. If yes, the generator adds the setup.py & setup.cfg files to be able to install the project as a dependency.

    To keep it simple, it did not add a pyproject.toml as recommended by the PEP 518 and it does not create any sub directory. It can be easily added if needed or we might want to add "sub prompts" to customize the library mode.

    It only impacts Nile & Protostar as with Hardhat the generated code is automatically installable as a library.

    opened by codingant0 0
  • Support latest version of OpenZeppelin Contracts for Cairo

    Support latest version of OpenZeppelin Contracts for Cairo

    The ERC20/721 templates being generated by this project are not compatible with recent versions of Contracts for Cairo.

    There are two related parts:

    • [ ] 1. The contract template files (which are used if the user does not want to customize their contract) are targeting an old version of the libraries.
    • [ ] 2. The wizard API dependency (which is used if the user DOES want to customize their contract) needs to be updated to use the latest version of the @openzeppelin/wizard-cairo package.
    opened by ericglau 0
  • Improve generated tests for upgradeable contracts

    Improve generated tests for upgradeable contracts

    Improve generated tests for upgradeable ERC20/ERC721 contracts (contracts that are customized with OpenZeppelin Wizard and have the Upgradeable option enabled).

    Currently tests for upgradeable contracts only test for contract name.

    Similar to https://github.com/onlydustxyz/generator-starknet/issues/30 but must make use of Proxy contract.

    opened by ericglau 0
  • Cairo contract kickstarter command

    Cairo contract kickstarter command

    Description

    Implement a sub generator to quickly bootstrap a new Cairo contract.

    The CLI could guide the user and let the possibility to:

    • Choose contract name
    • Generate associated test file: y/n ?
    • Add one or multiple storage fields
      • type name
      • type field type
      • generate view: y/n ?
      • add in constructor: y/n ?
    • Generate constructor
    • Is Ownable: y/n ? If yes use Ownable_initializer(owner)

    Acceptance criteria

    • Contract is correctly generated based on user choices
    • The generated contract compiles
    • The associated test files pass
    Type: feature Duration: few days Context: intricated State: open Techno: cairo Difficulty: hard Techno: js 
    opened by abdelhamidbakhta 6
  • Generate CI workflows for Protostar (Github actions)

    Generate CI workflows for Protostar (Github actions)

    Description

    As a developer, I would like to have CI workflows generated for my project.

    The continuous integration is an important part of the development lifecycle, hence it would improve the dev UX if the generator could prepare CI workflows.

    Acceptance criteria

    • A new confirm choice is proposed to the user to choose whether or not to generate the CI files
    • CI files are generated and working with Protostar and Github actions
    Context: isolated Difficulty: intermediate Duration: few days State: open Type: build Techno: js 
    opened by abdelhamidbakhta 1
  • Generate CI workflows for Hardhat (Github actions)

    Generate CI workflows for Hardhat (Github actions)

    Description

    As a developer, I would like to have CI workflows generated for my project.

    The continuous integration is an important part of the development lifecycle, hence it would improve the dev UX if the generator could prepare CI workflows.

    Acceptance criteria

    • A new confirm choice is proposed to the user to choose whether or not to generate the CI files
    • CI files are generated and working with Hardhat and Github actions
    Context: isolated Difficulty: intermediate Duration: few days State: open Type: build Techno: js 
    opened by abdelhamidbakhta 0
Releases(v0.1.5)
  • v0.1.5(May 17, 2022)

    What's Changed

    • Change template name for .gitignore by @ericglau in https://github.com/onlydustxyz/generator-starknet/pull/22

    Full Changelog: https://github.com/onlydustxyz/generator-starknet/compare/v0.1.4...v0.1.5

    Source code(tar.gz)
    Source code(zip)
  • v0.1.4(May 16, 2022)

    generator-starknet

    This is a development platform to quickly generate, develop, & deploy smart contract based apps on StarkNet.

    Installation

    First, install Yeoman and generator-starknet using npm (we assume you have pre-installed node.js).
    Make sure you are using a python 3.7.

    With NPM:

    npm install -g yo
    npm install -g generator-starknet
    

    With Yarn:

    yarn global add yo
    yarn global add generator-starknet
    

    Then generate your new project:

    yo starknet
    

    Now follow what is written in the console

    Want to get involved?

    If you are reading this part it is probably because you want to get involve and help us expand this git repository.
    First you can have a look at the issues open. Read them and try to find one you think you can help on.
    If you don't find any issue that you can work on but still find anything that can be improved, feel free to make a PR!

    The first step should always be to fork this repository.
    If you didn't change the yeoman app then you can probably stop reading and just make a pull request (make sure what you are submitting is working).

    If you are updating the yeoman application it would be better that you test it locally first.
    So install yeoman and yeoman-generator and link the current repository as the yeoman instance:

    npm install -g yo
    npm install -g yeoman-generator
    npm install -g yosay
    npm link
    

    Npm link will allow to link a module to a local directory. So whenever you'll run

    yo starknet
    

    It'll use the app present in the folder you were when doing the command instead of looking into the node_modules directory .
    You can now try it locally!
    Once you are sure your dev is over just submit a pull request.

    Don't forget to insert the issue you are trying to solve in the name (#issueNumber), and add a small description with the relevant tags.

    License

    MIT © Only Dust

    Source code(tar.gz)
    Source code(zip)
  • v0.1.2(May 3, 2022)

    generator-starknet

    This is a development platform to quickly generate, develop, & deploy smart contract based apps on StarkNet.

    Installation

    First, install Yeoman and generator-starknet using npm (we assume you have pre-installed node.js).

    With NPM:

    npm install -g yo
    npm install -g generator-starknet
    

    With Yarn:

    yarn global add yo
    yarn global add generator-starknet
    

    Then generate your new project:

    yo starknet
    

    License

    MIT © Only Dust

    Source code(tar.gz)
    Source code(zip)
  • v0.1.0(May 3, 2022)

    What's Changed

    • First release

    New Contributors

    • @abdelhamidbakhta created the project and implemented the generator
    • @Bernardstanislas made their first contribution in https://github.com/onlydustxyz/generator-starknet/pull/1

    Full Changelog: https://github.com/onlydustxyz/generator-starknet/commits/v0.1.0

    Source code(tar.gz)
    Source code(zip)
Owner
Only Dust
Only Dust
A professional truffle solidity template with all necessary libraries that support developer to develop, debug, test, deploy solidity smart contract

solidity-truffle-template A professional truffle solidity template with necessary libraries that support to develop, compile, test, deploy, upgrade, v

ChimGoKien 6 Nov 4, 2022
Starknet Burner is a web/mobile wallet for Starknet that works as a plugin for Argent-X

A Javascript wallet to interact with Starknet from mobile and web applications. Warning ** Experimental Project ** This project is still in developmen

Don't Panic DAO 59 Jan 5, 2023
StarkNet support extension for VSCode. Visualize StarkNet contracts: view storage variables, external and view functions, and events.

StarkNet Explorer extension This VSCode extension quickly shows relevant aspects of StarkNet contracts: Storage variables of the current contract, and

Crytic 6 Nov 4, 2022
Quickly develop, deploy and test Solana programs from the browser.

Solana Playground SolPg allows you to quickly develop, deploy and test Solana programs(smart contracts) from the browser. Note SolPg is still in beta

solana-playground 176 Dec 29, 2022
SmartBuilder: A Block-based Visual Programming Framework for Smart Contract Development

SmartBuilder A Block-based Visual Programming Framework for Smart Contract Development Technology stack used SmartBuilder Framework - Google Blockly A

ibelab 4 Mar 29, 2022
Verbosely Documented, Minimal Starknet Contract Examples.

cairo-by-example • Verbosely Documented, Minimal Starknet Contract Examples. Cairo By Example deployed to https://cairo-by-example.xyz Developing Clon

andreas 63 Dec 6, 2022
A Typescript Hardhat-based template to develop evm-based smart contracts with all the tooling you need.

EVM-based Smart Contract Scaffold A Typescript Hardhat-based template to develop evm-based smart contracts with all the tooling you need. Features Use

Flair 8 Oct 24, 2022
Toolkit for development, test and deploy smart-contracts on Waves Enterprise ecosystem.

JS Contract SDK Toolkit for development, test and deploy smart-contracts on Waves Enterprise ecosystem. Quickstart The fastest way to get started with

Waves Enterprise 20 Dec 15, 2022
The project integrates workflow engine, report engine and organization authority management background, which can be applied to the development of OA, HR, CRM, PM and other systems. With tlv8 IDE, business system development, testing and deployment can be realized quickly.

介绍 项目集成了工作流引擎、报表引擎和组织机构权限管理后台,可以应用于OA、HR、CRM、PM等系统开发。配合使用tlv8 ide可以快速实现业务系统开发、测试、部署。 后台采用Spring MVC架构简单方便,前端使用流行的layui界面美观大方。 采用组件开发技术,提高系统的灵活性和可扩展性;采

Qian Chen 38 Dec 27, 2022
A comprehensive collection of useful tools developed with the help of Ethers.js to interact with the Ethereum Blockchain to develop great DeFi apps as quickly and easily as possible.

hudi-packages-ethersfactory How to install Installing with npm For more information on using npm check out the docs here. npm i @humandataincome/ether

HUDI 6 Mar 30, 2022
Web3-citizens-app - React application based on smart contract using web3 and MetaMask extention.

Citizens App (web3-react-redux) React application based on smart contract using web3 and MetaMask extention. Start the applicarion Recomend to install

Denys Voloshyn 3 Aug 25, 2022
Use thirdweb's token, edition drop, and a custom contract using thirdweb deploy to build a Play-to-Earn game!

thirdweb Play-to-Earn Example This example project is a simple Play-to-Earn (P2E) game! The Idea The game is a "mining" game, where your character min

thirdweb templates 28 Jan 2, 2023
ToolJet an open-source low-code framework to build and deploy internal tools quickly without much effort from the engineering teams

ToolJet is an open-source low-code framework to build and deploy internal tools quickly without much effort from the engineering teams. You can connect to your data sources, such as databases (like PostgreSQL, MongoDB, Elasticsearch, etc), API endpoints (ToolJet supports importing OpenAPI spec & OAuth2 authorization), and external services (like Stripe, Slack, Google Sheets, Airtable) and use our pre-built UI widgets to build internal tools.

ToolJet 15.6k Jan 3, 2023
Weaver IBAX IDE. IBAX Network offers a polished development tool Weaver to develop DApps for ecoLibs (side chains).

Weaver Provide the user interface for ibax. Provide the IDE for App development. Save the private key of the user account and grant the permissions. R

IBAX PUBLIC NETWORK 51 Nov 4, 2022
A tool that enables developers to connect multiple applications without the need to develop any interface.

Flooq A tool that enables developers to connect multiple applications without the need to develop any interface. Environments Env Service Status stagi

Agile Waterfall Inc. 8 Jul 1, 2022
A simple library for Node and the browser that allows you to rapidly develop stateful, socketed multiplayer games and web applications.

gameroom.js Overview gameroom.js is a simple library for Node and the browser that allows you to rapidly develop stateful, socketed multiplayer games

Jackson Bierfeldt 3 Nov 3, 2022
First smart contract deployed on Rinkeby.

Inbox-Contract First smart contract deployed on Rinkeby. It has a basic constructor which accpets a string and assigns the string to the message varia

Stanley Moukhametzianov 1 Dec 26, 2021
Aergo Timer Service schedule smart contract function calls

Aergo Timer Service ⏰ Create timers to call functions on your smart contracts Schedule calls based on time interval or on specific date-times For a sm

aergo 3 Mar 10, 2022
Blockchain, Smart Contract, Ganache, Remix, Web3, Solidity, Java Script, MQTT, ESP32, RFID, DHT11,

Blockchain, Smart Contract, Ganache, Remix, Web3, Solidity, Java Script, MQTT, ESP32, RFID, DHT11,

Hajar OUAAROUCH 5 May 24, 2022