Skip to content

Instantly share code, notes, and snippets.

View app.component.ts
import { Component, ViewChild, CUSTOM_ELEMENTS_SCHEMA, NO_ERRORS_SCHEMA } from '@angular/core';
import { Router } from '@angular/router';
import { Platform, MenuController, AlertController} from '@ionic/angular';
import { SplashScreen } from '@ionic-native/splash-screen/ngx';
import { StatusBar } from '@ionic-native/status-bar/ngx';
import md5 from 'crypto-js/md5';
import { NetworkCheckProvider } from './services/network-check/network-check';
import { AppConfigProvider } from './services/app-config/app-config';
import { AuthProvider } from './services/auth/auth';
import { RedirectorProvider } from './services/redirector/redirector';
View app.component.html
<ion-app>
<ion-menu contentId="content">
<ion-header>
<ion-toolbar padding>
<ion-title>Menu</ion-title>
</ion-toolbar>
</ion-header>
<ion-content>
<ion-list class="menu-left">
@fredroo
fredroo / sanitize-filename.php
Created Mar 27, 2019
Add Sanitize Filename to Plugin: Media File Renamer (Auto Rename) By Jordy Meow
View sanitize-filename.php
<?php
/* https://wordpress.org/plugins/media-file-renamer/ */
add_filter( 'mfrh_new_filename', 'my_filter_filename', 10, 3 );
function my_filter_filename( $filename, $old, $post ) {
$sanitized_filename = remove_accents( $filename ); // Convert to ASCII
@fredroo
fredroo / error
Created Jun 11, 2018
Error build --prod
View error
λ ionic cordova build android --prod
Running app-scripts build: --prod --platform android --target cordova
[18:20:00] build prod started ...
[18:20:00] clean started ...
[18:20:00] clean finished in 3 ms
[18:20:00] copy started ...
[18:20:00] ngc started ...
Error: Metadata version mismatch for module d:/Desenvolvimento/xampp/htdocs/app-reciklado-ionic-temp/node_modules/@agm/core/services/google-maps-types.d.ts, found version 4, expected 3
at StaticSymbolResolver.getModuleMetadata (d:\Desenvolvimento\xampp\htdocs\app-reciklado-ionic-temp\node_modules\@angular\compiler\bundles\compiler.umd.js:24474:34)
at StaticSymbolResolver._createSymbolsOf (d:\Desenvolvimento\xampp\htdocs\app-reciklado-ionic-temp\node_modules\@angular\compiler\bundles\compiler.umd.js:24260:46)
View .env.json
{
"API_URL": "http://192.168.1.9:8081/api",
"TOKEN_NAME": "token",
"WP_URL": "https://reciklado.com",
"GOOGLE_API_KEY": "AIzaSyDLQQCvYHqdw8kdIWGx6lY2VXFbt7Nx4c8"
}
@fredroo
fredroo / digitalocean-promo-code-february-march-april-2018.md
Last active Sep 9, 2018
Digital Ocean Promo Code for July / August / September 2018
View digitalocean-promo-code-february-march-april-2018.md

Digital Ocean Promo Code for July / August / September 2018

Save $25 for your Cloud Computing Solution with Digital Ocean.

How to get the Discount?

1.) Use this link to Sign Up and save your first $10.

2.) Enter the Promocode LOWENDBOX when you choose your payment method and get another $15 discount.