Oksydan / falcon

Prestashop starter theme that provides great development experience.
GNU General Public License v3.0
264 stars 63 forks source link

Some resource not correctly linked after first installation #329

Closed ludimassa closed 1 year ago

ludimassa commented 1 year ago

Description

Hi everyone, I would start building my first falcon theme By following the guide under xampp in a site without setting virtual host I have the follow error only for some resource Screenshot 2023-11-14 181301

Node.js version

18

php version

7.4

OS and it's version

windows

Browsers

No response

Required module/theme

theme

Reproduction steps

1. Install by following the guide under localhost/myprestashoppath/

Logs

No response

Oksydan commented 1 year ago

Hi,

It clearly not a bug but problem with your configuration. What is your .env files?

ludimassa commented 1 year ago

PORT=3505 SERVER_ADDRESS=localhost SITE_URL=http://localhost PUBLIC_PATH=/dimassa812/themes/falcon/assets/ probably some part of code during compilation is not linked correctly without setting virtualhost

Oksydan commented 1 year ago

Hmm 🤔 this problem only occurs when you are working on your theme via dev command. For production build command it should work as expected. Be aware that it will required to build your theme with different public _path if your production/remote store environment isn't installed inside directory like your local environment.

ludimassa commented 1 year ago

After some configuration of vhost and some update in prestashop configuration table I haven't error But what are the correct way for generate the production templete to move all file online?

Oksydan commented 1 year ago

You should run build script if our publicPath in your local env isn't different than in your production you don't have to do anything. Just run build and you can move your assets to production. If your production publicPath is different you have to build your theme with different configuration for env file. Second option is to build theme assets with your CI/CD proces - recommended.

ludimassa commented 1 year ago

thanks