Run Client-Side examples
mainClient-side examples are located in the examples/ directory. You can run them using several different tasks depending on your testing needs:
run-mockormock: Runs the project onlocalhostusing a mocked version of the FBInstant SDK. This returns dummy data for every call and is ideal for rapid local iteration.run-distordist: Runs the project onlocalhostusing HTTPS and embeds it into the Facebook embedded player. This uses the production SDK with authentic, updated data. Note: You must have a validFB_appIdinconfig.json. If the game hangs at 0% loading, visithttps://localhost:8000to trust the development certificates.upload: Packages and uploads the project to Facebook Web Hosting. This is used to test the game in production mode, which is necessary for testing on mobile devices.
All tasks require the --project flag to specify which example to run.
# Run a project with a mocked SDK
yarn run-mock --project hello-world
# Run a project with the production SDK via HTTPS
yarn run-dist --project sending-messages
# Package and upload a project to Web Hosting
yarn upload --project ads