PHPNews

Vuex External File

Setup Vuex with external file [https://vuex.vuejs.org/installation.html](https://vuex.vuejs.org/installation.html) But after this make a file in the `resources/assets/js` called `store.js` then set it up as needed Here I will have one loading state ``` export default { state: { loading: true, }, getters: …

Continue reading »

Written by Alfred Nutile RSS - - Aggregated on Tuesday July 3, 2018


Dusk Screenshots to S3 of Failing tests

I can be really annoying to troubleshoot a failed test in Dusk when using CI systems. What I ended up doing was setting up my project to send these files to S3 on fail. Here are the steps ## Setup You App This is just S3 storage so make sure you have a bucket and a folder in the bucket to write to. Basically for …

Continue reading »

Written by Alfred Nutile RSS - - Aggregated on Tuesday June 26, 2018


Windows Dev Box Try 2 2018

Going to list somethings as I go. The Mac, in spite of Apple, is a great developer experience, here is to hoping the Windows, with the help of Microsoft, grows to be better and better as the improve it via user feedback to make it a great development box. ## Links This started it all [https://char.gd/blog/2017/how-t…

Continue reading »

Written by Alfred Nutile RSS - - Aggregated on Tuesday June 19, 2018


Windows Dev Box Try 2 2018

Going to list somethings as I go. The Mac, in spite of Apple, is a great developer experience, here is to hoping the Windows, with the help of Microsoft, grows to be better and better as the improve it via user feedback to make it a great development box. ## Links This started it all [https://char.gd/blog/2017/how-t…

Continue reading »

Written by Alfred Nutile RSS - - Aggregated on Saturday June 16, 2018


Windows Dev Box Try 2 2018

Going to list somethings as I go. The Mac, in spite of Apple, is a great developer experience, here is to hoping the Windows, with the help of Microsoft, grows to be better and better as the improve it via user feedback to make it a great development box. ## Links This started it all [https://char.gd/blog/2017/how-t…

Continue reading »

Written by Alfred Nutile RSS - - Aggregated on Wednesday June 13, 2018


Windows Dev Box Try 2 2018

Going to list somethings as I go. The Mac, in spite of Apple, is a great developer experience, here is to hoping the Windows, with the help of Microsoft, grows to be better and better as the improve it via user feedback to make it a great development box. ## Links This started it all [https://char.gd/blog/2017/how-t…

Continue reading »

Written by Alfred Nutile RSS - - Aggregated on Tuesday June 12, 2018


Windows Dev Box Try 2 2018

Going to list somethings as I go ## Links This started it all [https://char.gd/blog/2017/how-to-set-up-the-perfect-modern-dev-environment-on-windows](https://char.gd/blog/2017/how-to-set-up-the-perfect-modern-dev-environment-on-windows) ## NPM and Composer install take a long time Some of this is the Windowsantimal…

Continue reading »

Written by Alfred Nutile RSS - - Aggregated on Monday June 11, 2018


Windows Dev Box Try 2 2018

Going to list somethings as I go ## NPM and Composer install take a long time Some of this is the Windowsantimalware running. If you go to Windows Security -> Exclusion you can have it not search this folder. More info [https://blog.emsisoft.com/en/28620/antimalware-service-executable/](https://blog.emsisoft.com/…

Continue reading »

Written by Alfred Nutile RSS - - Aggregated on Monday June 11, 2018


Query Strings and VueJS

Quick way to make the url reflect the query string so the user can share the url and filters. This is component based VueJS building so not an SPA But I still install `"vue-router": "^3.0.1"` And load it ``` import VueRouter from 'vue-router'; Vue.use(VueRouter); ``` The on the component I set a watch on the …

Continue reading »

Written by Alfred Nutile RSS - - Aggregated on Tuesday May 8, 2018


Lambda and Github Webhooks

Related to https://developer.github.com/webhooks/ and pushing data to Lambda AWS. I can check the token by just having this check in my handler. ``` const crypto = require('crypto'); exports.handler = (event, context, callback) => { let headers = event.headers; let body = event.body; if (typeof body === …

Continue reading »

Written by Alfred Nutile RSS - - Aggregated on Tuesday May 8, 2018


Debugging AWS SAM

This took a few to get just right, for one the command needs to be in the correct order ``` sam local invoke --event fixtures/latest_not_working.json -d 5858 GithubPushes ``` From here it gave me the output I was looking for: ``` sam local invoke --event fixtures/latest_not_working.json -d 5858 GithubPushes 2018/05…

Continue reading »

Written by Alfred Nutile RSS - - Aggregated on Monday May 7, 2018


BrowserSync and Laravel

Quick reminder to take advantage of this amazing feature [https://laravel.com/docs/5.6/mix#browsersync-reloading](https://laravel.com/docs/5.6/mix#browsersync-reloading) No more reloading your browser. ``` yarn add browser-sync --dev ``` then to your `webpack.mix.js` e.g. the domain of the site you are working …

Continue reading »

Written by Alfred Nutile RSS - - Aggregated on Monday March 19, 2018


GroupBy not Sorting by latest

Just to make this easy to find. I had a report to write which had numerous daily rows of the same related model data. So in this cause I was tracking servers and security reports. My reports where daily like this | id | server_id | failed | type | | ------------- |:-------------:| -----:| ---| |1|1…

Continue reading »

Written by Alfred Nutile RSS - - Aggregated on Sunday March 18, 2018


BrowserSync and Laravel

Quick reminder to take advantage of this amazing feature [https://laravel.com/docs/5.6/mix#browsersync-reloading](https://laravel.com/docs/5.6/mix#browsersync-reloading) No more reloading your browser. ``` yarn add browser-sync --dev ``` then to your `webpack.mix.js` e.g. the domain of the site you are working …

Continue reading »

Written by Alfred Nutile RSS - - Aggregated on Thursday March 15, 2018


Wrapping Libraries in Services JS

Just a note to self that when using libraries like `sweetalert` for example and then I want to convert to `sweetalert2`, it would have saved a lot of time to wrap it into a "service" and import that. For example I made this js file `services/Alerts.js`: ``` import swal from 'sweetalert2'; export default { …

Continue reading »

Written by Alfred Nutile RSS - - Aggregated on Monday March 5, 2018