Skip to content

Instantly share code, notes, and snippets.

View sabit990928's full-sized avatar
🎯
Focusing

Sabit Rakhim sabit990928

🎯
Focusing
View GitHub Profile
@idlehands
idlehands / 00_info.md
Last active May 20, 2023 11:28
-info and links
@atolemysov
atolemysov / gist:e035e1a7ff283c2d4c1bcd259c1a6f2e
Created October 26, 2019 04:55
ASP .net code-generator
https://www.nuget.org/packages/dotnet-aspnet-codegenerator/
---dotnet tool install --global dotnet-aspnet-codegenerator --version 3.0.0
https://gavilan.blog/2018/04/28/asp-net-core-2-doing-scaffolding-with-dotnet-cli-aspnet-codegenerator/
---dotnet aspnet-codegenerator controller -name GameController -actions -outDir Controllers -m Game -dc GeneralContext
Must be created model, DBContext.
@kosson
kosson / redincredid.ctrl.js
Created October 21, 2019 08:25
This is how content data generated by Editor.js could be transformed back into html.
const resursaModel = require('../../models/resursa-red');
const competenteS = require('../../models/competenta-specifica');
module.exports = (params) => {
return resursaModel.find({_id: params.idres}).populate({
path: 'competenteS'
}).exec().then( (resursa) => {
// console.log(resursa);
if (resursa[0].content) {
let articleHTML = '';
resursa[0].content.blocks.map(obj => {
@gaearon
gaearon / index.html
Last active January 26, 2024 11:25
Add React in One Minute
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8" />
<title>Add React in One Minute</title>
</head>
<body>
<h2>Add React in One Minute</h2>
<p>This page demonstrates using React with no build tooling.</p>
@joshbuchea
joshbuchea / semantic-commit-messages.md
Last active May 6, 2024 07:52
Semantic Commit Messages

Semantic Commit Messages

See how a minor change to your commit message style can make you a better programmer.

Format: <type>(<scope>): <subject>

<scope> is optional

Example

@wojteklu
wojteklu / clean_code.md
Last active May 6, 2024 11:43
Summary of 'Clean code' by Robert C. Martin

Code is clean if it can be understood easily – by everyone on the team. Clean code can be read and enhanced by a developer other than its original author. With understandability comes readability, changeability, extensibility and maintainability.


General rules

  1. Follow standard conventions.
  2. Keep it simple stupid. Simpler is always better. Reduce complexity as much as possible.
  3. Boy scout rule. Leave the campground cleaner than you found it.
  4. Always find root cause. Always look for the root cause of a problem.

Design rules

@yaycode
yaycode / 0 - instachat.md
Last active April 29, 2023 02:57
Elixir + Phoenix : Creating a simple chatroom

Instachat

The Phoenix Framework was built with realtime communication as a first class priority. Using its built in socket handling and channels we can implement a basic, realtime chat application with little effort.

For this video we’re going to assume that you already have Elixir and Phoenix Setup. You will not need a database as the messages will not be persisted. This tutorial is taken pretty much directly from the Phoenix Documentation.

Setting up the app

To start let’s generate a standard phoenix application:

$> mix phoenix.new instachat

@kangax's ES6 quiz, explained

@kangax created a new interesting quiz, this time devoted to ES6 (aka ES2015). I found this quiz very interesting and quite hard (made myself 3 mistakes on first pass).

Here we go with the explanations:

Question 1:
(function(x, f = () =&gt; x) {
@gokulkrishh
gokulkrishh / media-query.css
Last active May 5, 2024 08:25
CSS Media Queries for Desktop, Tablet, Mobile.
/*
##Device = Desktops
##Screen = 1281px to higher resolution desktops
*/
@media (min-width: 1281px) {
/* CSS */
@digitaljhelms
digitaljhelms / gist:4287848
Last active April 26, 2024 10:44
Git/GitHub branching standards & conventions

Branching

Quick Legend

Description, Instructions, Notes
Instance Branch