👩‍💻 Edit code

Learn how to edit code in your Flutter project.

Now that you are able to install the echoAR plugin in your Flutter, it's time to build a project.

We recommend that you clone Flutter + echoAR example project.

Initialize project

Import the project dependencies by running the following in the terminal:

flutter pub get

Add content

1. Add the 3D content in the models folder (nyancat.gif and stones.jpg) through the console.

2. Add a 3D model and choose the suggested sample 3D model of the Arctic Fox.

Edit code

Open the main.dart file from the lib folder, and make the following changes:

  • Replace <Your-API-Key> with your echoAR API key

  • Replace <Stones-Entry-ID> with the stones image entry ID on echoAR.

  • Replace <Gif-Entry-ID> with the GIF model entry ID on echoAR.

  • Replace <Fox-Entry-ID> with the fox model entry ID on echoAR.

You can find the entry IDs on the bottom of the back side of the content cards or Data page.

Now your project is ready to go! 🎉