Skip to content

Instantly share code, notes, and snippets.

View Blazing-Mike's full-sized avatar
👷
Focusing

Michael Blazing-Mike

👷
Focusing
  • Earth C-137
View GitHub Profile
console.log("hello webflow");
alert("Hello World!");
@Blazing-Mike
Blazing-Mike / index.html
Last active September 29, 2024 16:58
Solution multiple carousel
<div class="wrapper">
<div class="imageContainer">
<div class="example-img-container" style="--interval:7939.155745263944">
<img src="https://a.storyblok.com/f/144881/7a42170da0/orchardside-school-41.jpg/m/500x0" alt="" loading="lazy">
<img src="https://a.storyblok.com/f/144881/2048x1365/2dc5855066/ws_neonflex_illuminated-signs_58.jpg/m/500x0" alt="" loading="lazy">
</div>
<div class="example-img-container" style="--interval:9939.155745263944">
<img src="https://a.storyblok.com/f/144881/7a42170da0/orchardside-school-41.jpg/m/500x0" alt="" loading="lazy">
<img src="https://a.storyblok.com/f/144881/2048x1365/2dc5855066/ws_neonflex_illuminated-signs_58.jpg/m/500x0" alt="" loading="lazy">
</div>
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { ButtonComponent } from './button.component';
describe('ButtonComponent', () => {
let component: ButtonComponent;
let fixture: ComponentFixture<ButtonComponent>;
beforeEach(async () => {
await TestBed.configureTestingModule({
.bg-button {
background-color: #140c00;
}
.btn-success.disabled,
.btn-success:disabled {
cursor: not-allowed;
}
:host {
import {
Component,
Input,
EventEmitter,
Output,
ChangeDetectionStrategy,
} from '@angular/core';
@Component({
selector: 'app-button',
<button class="btn btn-dark nob-btn" type="{{ buttonType }}" [disabled]="loading" (click)="onButtonClick()">
<span class="my-3">{{ buttonText }}</span>
<div class="spinner-border spinner-border-sm absolute text-white font-size-10 fw-bold float-right" *ngIf="loading"
role="status">
<span class="sr-only">Loading...</span>
</div>
</button>
export const OfflineStatusModal = () => {
return (
<div className="justify-center items-center bg-black/80 flex overflow-x-hidden overflow-y-auto fixed inset-0 z-50 outline-none focus:outline-none">
<div className="relative w-auto my-6 mx-auto max-w-3xl">
{/*content*/}
<div className="border-0 rounded-lg shadow-lg relative flex flex-col w-full bg-background outline-none focus:outline-none">
import { useState, useEffect } from 'react';
async function performNetworkCheck() {
const endpoint = 'https://www.google.com';
try {
const response = await fetch(endpoint, {
method: 'HEAD',
cache: 'no-cache',
mode: 'no-cors',
{
"workbench.startupEditor": "none",
"window.autoDetectColorScheme": true,
"workbench.preferredDarkColorTheme": "Min Dark",
"workbench.preferredLightColorTheme": "Min Light",
"editor.minimap.enabled": false,
"breadcrumbs.enabled": false,
"editor.renderWhitespace": "all",
"emmet.includeLanguages": {
"javascript": "javascriptreact"
@Blazing-Mike
Blazing-Mike / loop-over-obj.ts
Created December 4, 2022 23:52
Loop over JSON object with angular ngfor
<ng-container *ngFor="let item of APIresponse | keyvalue: indexOrderAsc">
{{item.key.replaceAll('_', ' ') | titlecase}}:{{item.value}}
</ng-container>