25.06.2018 Views

Full-Stack Vue.js 2 and Laravel 5

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Running the FTP script<br />

The first time you run the FTP script you will need to copy all the files,<br />

including images. This will take some time, probably 20 to 30 minutes<br />

depending on your Internet connection speed: $ npm run prod && npm run<br />

ftp-deploy-with-images<br />

Once the transfer completes, uploaded files will be available at the zone URL,<br />

for example, http://vuebnb-9c0f.kxcdn.com. The path to a file will be relative to the<br />

public folder, for example, public/css/vue-style.css will be available at<br />

[ZONE_URL]/css/vue-style.css.<br />

Test a few files to ensure the transfer was successful: ><br />

Figure 10.4. Testing CDN files Subsequent transfers can skip the images by using this comm<strong>and</strong>: $ npm<br />

run prod && npm run ftp-deploy

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!