In the project, the image path needs to be dynamically loaded, and the image path is not the data obtained from the background.
Therefore , it must be loaded with require in data , otherwise it will be treated as a string.
HTML is as follows:
JS is as follows: