我当前正在尝试部署SPA反应并向aws表达Web应用程序。从服务器方面来说,我有一条使用nodemailer
api发送电子邮件的服务器路由。
我正在使用webpack来创建包含所有资产的包和dist文件夹。
我的应用程序的结构如下:
|src
| |-dist
| | |-assets
| | | |-src
| | | | |-public
| | | | | |-images
| |-universal
| | |-utils
| | | |-validation
| | |-components
| | | |-home
| | | |-footer
| | | |-contact
| | | |-app
| | | |-projects
| | | |-resume
| | | |-navigation
| | | |-about
| | | |-common
| | | | |-ErrorMessage
| | | | |-Banner
| | | |-media
| | |-actions
| | | |-app
| | |-reducers
| | | |-app
| |-server
| | |-routes
| | | |-sendEmail
| |-public
| | |-images
| | |-documents
| | |-src
| | | |-public
| | | | |-images
| | | | |-documents
| |-data
| |-client
| | |-styles
我有2个问题:
../../../../public/images
获取图像,但是dist文件夹配置为dist/assets/src/public/images
,关于此配置路径的最佳方法是什么。