I have an .js file where I have my books as bellow:
export const booksData = [
{
id: "1",
title: "1491",
description: "A fantastic historical book",
genre: 'Historical',
image: "https://shop.radical-guide.com/wp-content/uploads/2020/06/1491-Front.jpg"
},
How can I import and display these books dynamically in my react application?
import { booksData } from "path/to/file.js"
– Phil.js
file to change? If so, when and how does it change? If not, you can simply bundle it by importing it as above – Phil