(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3213],{26807:function(e,i,s){(window.__NEXT_P=window.__NEXT_P||[]).push(["/en/build/get-started/developer-setup",function(){return s(4084)}])},66426:function(e,i){"use strict";i.Z={src:"/_next/static/media/cad-video.5a4e8efd.gif",height:311,width:600,blurWidth:0,blurHeight:0}},4084:function(e,i,s){"use strict";s.r(i),s.d(i,{useTOC:function(){return p}});var t=s(31549),a=s(82910),n=s(15801),r=s(46977),d=s(66426),l=s(92907),h=s(47023),o=s(9029),c=s(83185);function p(e){let i={code:"code",...(0,r.a)()};return[{value:"Initialize Frontend Project",id:"initialize-frontend-project",depth:3},{value:(0,t.jsxs)(t.Fragment,{children:["Install ",(0,t.jsx)(i.code,{children:"@aptos-labs/ts-sdk"})]}),id:"install-aptos-labsts-sdk",depth:3},{value:"Setup TS SDK",id:"setup-ts-sdk",depth:3},{value:"Build your app!",id:"build-your-app",depth:3},{value:"Install CLI",id:"install-cli",depth:3},{value:"Setup Editor or IDE",id:"setup-editor-or-ide",depth:3},{value:"Create Smart Contract",id:"create-smart-contract",depth:3},{value:"Build, Compile, and Deploy Smart Contract!",id:"build-compile-and-deploy-smart-contract",depth:3},{value:(0,t.jsxs)(t.Fragment,{children:["Install ",(0,t.jsx)(i.code,{children:"create-aptos-dapp"})]}),id:"install-create-aptos-dapp",depth:3},{value:"Follow the prompts",id:"follow-the-prompts",depth:3},{value:"Start building and customizing your new dApp!",id:"start-building-and-customizing-your-new-dapp",depth:3},{value:"Continue reading",id:"continue-reading",depth:3}]}function x(e,i){throw Error("Expected "+(i?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}i.default=(0,a.c)(function(e){let{toc:i=p(e)}=e,s={a:"a",code:"code",h1:"h1",h3:"h3",img:"img",p:"p",pre:"pre",span:"span",...(0,r.a)(),...e.components};return l.m||x("$Tabs",!1),l.m.Tab||x("$Tabs.Tab",!0),o.Zb||x("Card",!1),o.Zb.Description||x("Card.Description",!0),o.Zb.Title||x("Card.Title",!0),l.m||x("Tabs",!1),l.m.Tab||x("Tabs.Tab",!0),(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(s.h1,{children:"Developer Setup"}),"\n",(0,t.jsx)(s.p,{children:"Here is an easy way to setup your environment depending on the type of development."}),"\n",(0,t.jsxs)(l.m,{items:["Frontend","Smart Contract","Create Aptos Dapp"],children:[(0,t.jsx)(l.m.Tab,{children:(0,t.jsxs)(h.R,{children:[(0,t.jsx)(s.h3,{id:i[0].id,children:i[0].value}),(0,t.jsx)(s.p,{children:"Here are some examples of popular choices:"}),(0,t.jsxs)(l.m,{items:["Next.js","Vite (TS)"],children:[(0,t.jsx)(l.m.Tab,{children:(0,t.jsx)(s.pre,{icon:c.Fx,tabIndex:"0","data-language":"bash","data-word-wrap":"","data-filename":"Terminal","data-copy":"",children:(0,t.jsx)(s.code,{children:(0,t.jsxs)(s.span,{children:[(0,t.jsx)(s.span,{style:{"--shiki-light":"#6F42C1","--shiki-dark":"#B392F0"},children:"pnpx"}),(0,t.jsx)(s.span,{style:{"--shiki-light":"#032F62","--shiki-dark":"#9ECBFF"},children:" create-next-app@latest"})]})})})}),(0,t.jsx)(l.m.Tab,{children:(0,t.jsx)(s.pre,{icon:c.Fx,tabIndex:"0","data-language":"bash","data-word-wrap":"","data-filename":"Terminal","data-copy":"",children:(0,t.jsx)(s.code,{children:(0,t.jsxs)(s.span,{children:[(0,t.jsx)(s.span,{style:{"--shiki-light":"#6F42C1","--shiki-dark":"#B392F0"},children:"pnpx"}),(0,t.jsx)(s.span,{style:{"--shiki-light":"#032F62","--shiki-dark":"#9ECBFF"},children:" create"}),(0,t.jsx)(s.span,{style:{"--shiki-light":"#032F62","--shiki-dark":"#9ECBFF"},children:" vite"}),(0,t.jsx)(s.span,{style:{"--shiki-light":"#032F62","--shiki-dark":"#9ECBFF"},children:" my-aptos-app"}),(0,t.jsx)(s.span,{style:{"--shiki-light":"#005CC5","--shiki-dark":"#79B8FF"},children:" --template"}),(0,t.jsx)(s.span,{style:{"--shiki-light":"#032F62","--shiki-dark":"#9ECBFF"},children:" react-ts"})]})})})})]}),(0,t.jsx)(s.h3,{id:i[1].id,children:i[1].value}),(0,t.jsxs)(l.m,{items:["npm","pnpm","yarn","bun"],storageKey:"selectedPackageManager",children:[(0,t.jsx)(l.m.Tab,{children:(0,t.jsx)(s.pre,{icon:c.Fx,tabIndex:"0","data-language":"bash","data-word-wrap":"","data-copy":"",children:(0,t.jsx)(s.code,{children:(0,t.jsxs)(s.span,{children:[(0,t.jsx)(s.span,{style:{"--shiki-light":"#6F42C1","--shiki-dark":"#B392F0"},children:"npm"}),(0,t.jsx)(s.span,{style:{"--shiki-light":"#032F62","--shiki-dark":"#9ECBFF"},children:" i"}),(0,t.jsx)(s.span,{style:{"--shiki-light":"#032F62","--shiki-dark":"#9ECBFF"},children:" @aptos-labs/ts-sdk"})]})})})}),(0,t.jsx)(l.m.Tab,{children:(0,t.jsx)(s.pre,{icon:c.Fx,tabIndex:"0","data-language":"bash","data-word-wrap":"","data-copy":"",children:(0,t.jsx)(s.code,{children:(0,t.jsxs)(s.span,{children:[(0,t.jsx)(s.span,{style:{"--shiki-light":"#6F42C1","--shiki-dark":"#B392F0"},children:"pnpm"}),(0,t.jsx)(s.span,{style:{"--shiki-light":"#032F62","--shiki-dark":"#9ECBFF"},children:" add"}),(0,t.jsx)(s.span,{style:{"--shiki-light":"#032F62","--shiki-dark":"#9ECBFF"},children:" @aptos-labs/ts-sdk"})]})})})}),(0,t.jsx)(l.m.Tab,{children:(0,t.jsx)(s.pre,{icon:c.Fx,tabIndex:"0","data-language":"bash","data-word-wrap":"","data-copy":"",children:(0,t.jsx)(s.code,{children:(0,t.jsxs)(s.span,{children:[(0,t.jsx)(s.span,{style:{"--shiki-light":"#6F42C1","--shiki-dark":"#B392F0"},children:"yarn"}),(0,t.jsx)(s.span,{style:{"--shiki-light":"#032F62","--shiki-dark":"#9ECBFF"},children:" add"}),(0,t.jsx)(s.span,{style:{"--shiki-light":"#032F62","--shiki-dark":"#9ECBFF"},children:" @aptos-labs/ts-sdk"})]})})})}),(0,t.jsx)(l.m.Tab,{children:(0,t.jsx)(s.pre,{icon:c.Fx,tabIndex:"0","data-language":"bash","data-word-wrap":"","data-copy":"",children:(0,t.jsx)(s.code,{children:(0,t.jsxs)(s.span,{children:[(0,t.jsx)(s.span,{style:{"--shiki-light":"#6F42C1","--shiki-dark":"#B392F0"},children:"bun"}),(0,t.jsx)(s.span,{style:{"--shiki-light":"#032F62","--shiki-dark":"#9ECBFF"},children:" add"}),(0,t.jsx)(s.span,{style:{"--shiki-light":"#032F62","--shiki-dark":"#9ECBFF"},children:" @aptos-labs/ts-sdk"})]})})})})]}),(0,t.jsx)(s.h3,{id:i[2].id,children:i[2].value}),(0,t.jsx)(o.oy,{children:(0,t.jsxs)(o.Zb,{href:"../sdks/ts-sdk/quickstart",children:[(0,t.jsx)(o.Zb.Title,{children:"TS SDK Quickstart"}),(0,t.jsx)(o.Zb.Description,{children:"See how to setup your account, network, use the\nfaucet, send / simulate transactions, and more"})]})}),(0,t.jsx)(s.h3,{id:i[3].id,children:i[3].value}),(0,t.jsx)(s.p,{children:"The developer setup for using Aptos in your frontend is now complete.\nCheckout our other tools that streamline the development process"}),(0,t.jsxs)(o.oy,{children:[(0,t.jsxs)(o.Zb,{href:"../indexer",children:[(0,t.jsx)(o.Zb.Title,{children:"Indexer"}),(0,t.jsx)(o.Zb.Description,{children:"Efficiently query for on-chain state like balances,\ntransaction activity, token data, and more"})]}),(0,t.jsxs)(o.Zb,{href:"https://github.com/aptos-labs/aptos-ts-sdk/tree/main/examples/typescript",children:[(0,t.jsx)(o.Zb.Title,{linkType:"external",children:"TS SDK Examples"}),(0,t.jsx)(o.Zb.Description,{children:"20+ Examples of how to use the TS\nSDK"})]}),(0,t.jsxs)(o.Zb,{href:"https://developers.aptoslabs.com/",children:[(0,t.jsx)(o.Zb.Title,{linkType:"external",children:"API Gateway"}),(0,t.jsx)(o.Zb.Description,{children:"Hitting rate limits for Fullnode API / Indexers? Get\nan API Key here"})]})]})]})}),(0,t.jsx)(l.m.Tab,{children:(0,t.jsxs)(h.R,{children:[(0,t.jsx)(s.h3,{id:i[4].id,children:i[4].value}),(0,t.jsx)(o.oy,{children:(0,t.jsxs)(o.Zb,{href:"../cli",children:[(0,t.jsx)(o.Zb.Title,{children:"Aptos CLI"}),(0,t.jsx)(o.Zb.Description,{children:(0,t.jsx)(s.p,{children:"Instructions for how to install Aptos CLI"})})]})}),(0,t.jsx)(s.h3,{id:i[5].id,children:i[5].value}),(0,t.jsx)(s.p,{children:"Add the following extensions to your editor of choice to make Move\nDevelopment easier"}),(0,t.jsxs)(l.m,{items:["JetBrains IDE","VSCode"],children:[(0,t.jsx)(l.m.Tab,{children:(0,t.jsx)(o.oy,{children:(0,t.jsxs)(o.Zb,{href:"https://plugins.jetbrains.com/plugin/14721-move-language",children:[(0,t.jsx)(o.Zb.Title,{linkType:"external",children:"Move Language"}),(0,t.jsx)(o.Zb.Description,{children:"Language server and syntax highlighter for\nJetBrains IDEs like CLion, Rust Rover, WebStorm,\nIntelliJ"})]})})}),(0,t.jsx)(l.m.Tab,{children:(0,t.jsx)(o.oy,{children:(0,t.jsxs)(o.Zb,{href:"https://marketplace.visualstudio.com/items?itemName=MoveBit.aptos-move-analyzer",children:[(0,t.jsx)(o.Zb.Title,{linkType:"external",children:"Aptos Move Analyzer"}),(0,t.jsx)(o.Zb.Description,{children:"Language server and syntax highlighter for\nVSCode"})]})})})]}),(0,t.jsx)(s.h3,{id:i[6].id,children:i[6].value}),(0,t.jsx)(s.p,{children:"Navigate to your application folder and initialize a new smart contract by\ndoing:"}),(0,t.jsx)(s.pre,{icon:c.Fx,tabIndex:"0","data-language":"sh","data-word-wrap":"","data-filename":"Terminal","data-copy":"",children:(0,t.jsx)(s.code,{children:(0,t.jsxs)(s.span,{children:[(0,t.jsx)(s.span,{style:{"--shiki-light":"#6F42C1","--shiki-dark":"#B392F0"},children:"aptos"}),(0,t.jsx)(s.span,{style:{"--shiki-light":"#032F62","--shiki-dark":"#9ECBFF"},children:" move"}),(0,t.jsx)(s.span,{style:{"--shiki-light":"#032F62","--shiki-dark":"#9ECBFF"},children:" init"}),(0,t.jsx)(s.span,{style:{"--shiki-light":"#005CC5","--shiki-dark":"#79B8FF"},children:" --name"}),(0,t.jsx)(s.span,{style:{"--shiki-light":"#032F62","--shiki-dark":"#9ECBFF"},children:" my_todo_list"})]})})}),(0,t.jsx)(s.h3,{id:i[7].id,children:i[7].value}),(0,t.jsx)(s.p,{children:"The developer setup for using Aptos for smart contracts is now complete.\nFor more info see the link to the Dapp tutorial below"}),(0,t.jsx)(o.oy,{children:(0,t.jsxs)(o.Zb,{href:"../guides/build-e2e-dapp/1-create-smart-contract#what-is-a-movetoml-file",children:[(0,t.jsx)(o.Zb.Title,{children:"Create Smart Contract Guide"}),(0,t.jsx)(o.Zb.Description,{children:"An easy todo list guide for how to setup a smart\ncontract with Move"})]})})]})}),(0,t.jsx)(l.m.Tab,{children:(0,t.jsxs)(h.R,{children:[(0,t.jsx)(s.h3,{id:i[8].id,children:i[8].value}),(0,t.jsx)(s.p,{children:"Run the below command to install a dApp from a template in seconds:"}),(0,t.jsxs)(l.m,{items:["npx","pnpx"],children:[(0,t.jsx)(l.m.Tab,{children:(0,t.jsx)(s.pre,{icon:c.Fx,tabIndex:"0","data-language":"bash","data-word-wrap":"","data-filename":"Terminal","data-copy":"",children:(0,t.jsx)(s.code,{children:(0,t.jsxs)(s.span,{children:[(0,t.jsx)(s.span,{style:{"--shiki-light":"#6F42C1","--shiki-dark":"#B392F0"},children:"npx"}),(0,t.jsx)(s.span,{style:{"--shiki-light":"#032F62","--shiki-dark":"#9ECBFF"},children:" create-aptos-dapp@latest"})]})})})}),(0,t.jsx)(l.m.Tab,{children:(0,t.jsx)(s.pre,{icon:c.Fx,tabIndex:"0","data-language":"bash","data-word-wrap":"","data-filename":"Terminal","data-copy":"",children:(0,t.jsx)(s.code,{children:(0,t.jsxs)(s.span,{children:[(0,t.jsx)(s.span,{style:{"--shiki-light":"#6F42C1","--shiki-dark":"#B392F0"},children:"pnpx"}),(0,t.jsx)(s.span,{style:{"--shiki-light":"#032F62","--shiki-dark":"#9ECBFF"},children:" create-aptos-dapp@latest"})]})})})})]}),(0,t.jsx)(s.h3,{id:i[9].id,children:i[9].value}),(0,t.jsxs)(s.p,{children:["Follow the CLI prompts to select a name, ",(0,t.jsx)(s.a,{href:"../create-aptos-dapp#templates",children:"template"}),", and network for your new dApp."]}),(0,t.jsx)(s.p,{children:(0,t.jsx)(s.img,{alt:"cad",src:d.Z})}),(0,t.jsx)(s.h3,{id:i[10].id,children:i[10].value}),(0,t.jsx)(s.p,{children:"Navigate to your new project and open in your favorite IDE to continue building!"}),(0,t.jsxs)(s.p,{children:["Follow the generated ",(0,t.jsx)(s.code,{children:"README.md"})," file for next steps."]}),(0,t.jsx)(s.h3,{id:i[11].id,children:i[11].value}),(0,t.jsxs)(o.oy,{children:[(0,t.jsxs)(o.Zb,{href:"../create-aptos-dapp",children:[(0,t.jsx)(o.Zb.Title,{children:"Create Aptos Dapp"}),(0,t.jsx)(o.Zb.Description,{children:"Get more information about the tool"})]}),(0,t.jsxs)(o.Zb,{href:"../create-aptos-dapp#templates",children:[(0,t.jsx)(o.Zb.Title,{children:"Templates"}),(0,t.jsx)(o.Zb.Description,{children:"Browse premade templates"})]}),(0,t.jsxs)(o.Zb,{href:"../create-aptos-dapp/faq",children:[(0,t.jsx)(o.Zb.Title,{children:"FAQ"}),(0,t.jsx)(o.Zb.Description,{children:"Get help for common issues and questions"})]})]})]})})]})]})},"/en/build/get-started/developer-setup",{filePath:"pages/en/build/get-started/developer-setup.mdx",timestamp:1728425436e3,pageMap:n.v,frontMatter:{title:"Developer Setup"},title:"Developer Setup"},"undefined"==typeof RemoteContent?p:RemoteContent.useTOC)},47023:function(e,i,s){"use strict";s.d(i,{R:function(){return r}});var t=s(31549),a=s(78364),n=s(44194);function r({children:e,className:i,style:s,...r}){let d=(0,n.useId)().replaceAll(":","");return(0,t.jsx)("div",{className:(0,a.Z)("nextra-steps _ms-4 _mb-12 _border-s _border-gray-200 _ps-6","dark:_border-neutral-800",i),style:{...s,"--counter-id":d},...r,children:e})}}},function(e){e.O(0,[49774,94249,27159,65411,57822,68889,43941,49296,52318,15801,9029,92888,40179],function(){return e(e.s=26807)}),_N_E=e.O()}]);