- Don't use classes in html based on styles
- i.e. instead of
.table .table-lined .shift-right .moar-styling
useuser-table
and use sass%placeholders
instead.
- i.e. instead of
- Place
@media
queries within each related component - Use
em
's and rem's instead ofpx
. (there's handy sass functions to convert px) - 99% of the time, avoid
table
s. instead, usediv
s to avoid the underlying styling challenges when usingtable
. - Don't nest reusable styles in shared scss files. This makes it difficult to see the impact of what styles are inherited and forces the consumer to override unwanted nested styles.
This file contains 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
{ | |
"extends": [ | |
"stylelint-config-standard-scss", | |
"stylelint-config-recommended-vue" | |
], | |
"plugins": [ | |
"stylelint-order" | |
], | |
"rules": { | |
"color-hex-length": "short", |
This file contains 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
module.exports = { | |
parser: 'vue-eslint-parser', | |
parserOptions: { | |
parser: '@typescript-eslint/parser', | |
ecmaVersion: 2022, | |
sourceType: 'module', | |
extraFileExtensions: ['.json'] | |
}, | |
env: { | |
node: true, |
This file contains 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
const createLogger = () => { | |
console.log("made it"); | |
const isProdMode = | |
process.env.NODE_ENV === "prod" || process.env.NODE_ENV === "production" | |
? true | |
: false; | |
//TODO: move this var to env file or a parameter | |
// level 1 = debug |
This file contains 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
{ | |
"extends": "stylelint-config-standard", | |
"plugins": [ | |
"stylelint-order", | |
"stylelint-scss" | |
], | |
"rules": { | |
"at-rule-no-unknown": null, | |
"color-hex-length": "short", | |
"color-named": "never", |
This file contains 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
public static async void FireAndForget<T>(this Task task, ILogger<T> logger) | |
{ | |
try | |
{ | |
await task; | |
} | |
catch (Exception e) | |
{ | |
logger.LogError(e, $"An exception occured during the fire and forget task: {e.GetBaseException()}"); | |
} |
This file contains 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
public static async Task<IEnumerable<U>> ForEachAsync<T, U>(this IEnumerable<T> items, Func<T, Task<U>> func, int _degreeOfParallelism = 100) | |
{ | |
var results = new List<U>(); | |
using (var semaphore = new SemaphoreSlim(_degreeOfParallelism)) | |
{ | |
var tasks = items.Select(async item => | |
{ | |
await semaphore.WaitAsync(); | |
try | |
{ |
This file contains 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
{ | |
"window.zoomLevel": 0, | |
"files.autoSave": "afterDelay", | |
"files.autoSaveDelay": 1200, | |
"git.confirmSync": false, | |
"workbench.iconTheme": "vscode-icons", | |
"explorer.openEditors.visible": 0, | |
"editor.matchBrackets": true, | |
"editor.fontFamily": "Fira Code, Menlo, Monaco, 'Courier New', monospace", | |
"editor.fontLigatures": true, |
This file contains 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
#Go to root dir | |
docker build -t my-image-name-here -f ./deploy/dockerfile ./ |
This file contains 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
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Reflection; | |
using System.Web.Mvc; | |
using Microsoft.Ajax.Utilities; | |
namespace Helpers.Web | |
{ | |
public class ControllerDesc |