This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### Keybase proof | |
I hereby claim: | |
* I am ngohungphuc on github. | |
* I am ngohungphuc (https://keybase.io/ngohungphuc) on keybase. | |
* I have a public key ASBmuVoaAY0YSWZO0pTgsk8lLuPVxM1B1DNlg-wQ4v2iXgo | |
To claim this, I am signing this object: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{"lastUpload":"2021-02-04T06:56:14.954Z","extensionVersion":"v3.4.3"} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var fs = require("fs"); | |
var minify = require("html-minifier").minify; | |
var filePath = "dist/index.html"; | |
fs.readFile(filePath, function (err, buf) { | |
if (err) { | |
console.log(err); | |
} else { | |
var originalValue = buf.toString(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{"lastUpload":"2020-11-30T13:15:04.206Z","extensionVersion":"v3.4.3"} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { HttpClient, HttpClientModule } from "@angular/common/http"; | |
import { | |
TranslateLoader, | |
TranslateModule, | |
TranslateService | |
} from "@ngx-translate/core"; | |
import { TranslateHttpLoader } from "@ngx-translate/http-loader"; | |
import { SharedModule } from "@shared/shared.module"; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
trigger: | |
- master | |
pool: | |
vmImage: 'windows-2019' | |
steps: | |
- script: | | |
git config --global core.longpaths true | |
git config --global user.email "your email" | |
git config --global user.name "your github user name" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// devtool.ts | |
import { StoreDevtoolsModule } from "@ngrx/store-devtools"; | |
export const StoreDevModules = [ | |
StoreDevtoolsModule.instrument({ | |
name: "Online book store" | |
}) | |
]; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"lint-step": { | |
"*.scss": [ | |
"stylelint src/**/*.scss" | |
], | |
"*.{ts,jsx}": [ | |
"ng lint" | |
] | |
}, | |
"husky": { | |
"hooks": { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"husky": { | |
"hooks": { | |
"pre-commit": "ng lint && ng build --prod" | |
} | |
}, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
initService() { | |
const conn = (navigator as any).connection; | |
if (conn) { | |
if (conn.saveData) { | |
// do something | |
} | |
const connectionlist = ["slow-2g", "2g", "3g", "4g"]; | |
const effectiveType = conn.effectiveType; | |
console.log(effectiveType); | |
} |
NewerOlder