Skip to content

Setup image import correctly #38

@mattam

Description

@mattam

Because we need to import our static local files at build time, we need to use the switch/case statement to require() in the files.

To keep things clean, we should namespace our data/tours/tour_0/images files so that they are distinguishable from future tour_1 files.

so the files should be named:

tour_0_chez-maman.jpg
tour_0_location_0.png
tour_0_vive-la-tarte.jpg

Also clean the switch/case statement so that it uses the new path. (Eventually we'll have to setup a smarter function to take in the tour_num and the file_name and construct the correct path to return the image require() from.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions