Skip to content

Instantly share code, notes, and snippets.

View AleksejDix's full-sized avatar
💚
in love with vue

Aleksej Dix AleksejDix

💚
in love with vue
View GitHub Profile
@nemanja947
nemanja947 / NprogressAxios.js
Last active October 7, 2023 01:44
NProgress implementation with Axios
// Add a request interceptor
axios.interceptors.request.use(function (config) {
// Do something before request is sent
NProgress.start();
return config;
}, function (error) {
// Do something with request error
console.error(error)
return Promise.reject(error);
});
@nirazul
nirazul / map-filters.js
Created June 4, 2017 11:28
Map global filters to local methods to use them in components as well as templates
/**
* Map global filters for being used from within `methods`. This makes them usable in js as well as templates
* @param {Array} filters - A list of registered filter names
* @return {Object) An object containing filters and their functions
*/
export function mapFilters(filters) {
return filters.reduce((result, filter) => {
result[filter] = function(...args) {
return this.$options.filters[filter](...args);
};
@cvrebert
cvrebert / css_regression_testing.md
Last active May 28, 2024 17:42
Survey of screenshot-based CSS testing tools

Currently considering https://github.com/webdriverio/webdrivercss


Core Goals:

  • Can test in up-to-date versions of all major browsers
  • Can test on up-to-date versions of all major OSes
  • Can test in IE9 (because Bootstrap v4 will support IE9+)
  • Don't want to have to setup/maintain our own cluster of VMs running all the necessary OSes (and all the versions of Windows)
  • Workflow for management of reference/baseline/norm screenshots