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
| /* /index.html 200 |
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
| @function encodecolor($string) { | |
| @if type-of($string) == 'color' { | |
| $hex: str-slice(ie-hex-str($string), 4); | |
| $string:unquote("#{$hex}"); | |
| } | |
| $string: '%23' + $string; | |
| @return $string; | |
| } | |
| @mixin x-twitter-icon($color: white, $width: 16px, $height: 16px, $square: false) { |
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
| document.onreadystatechange = () => { | |
| document.addEventListener("afOnReady", (ev) => { | |
| console.log("ready", ev); | |
| }) | |
| if (document.readyState === "complete") { | |
| console.log("complete") | |
| } | |
| } |
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
| function setResponsiveTables() { | |
| document.onreadystatechange = () => { | |
| if(document.readyState === 'complete') { | |
| const tables = document.querySelectorAll('table'); | |
| tables.forEach((table) => { | |
| const clone = table.cloneNode(true); | |
| const wrapper = document.createElement('div'); | |
| wrapper.classList.add('table-responsive'); | |
| wrapper.appendChild(clone); |
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
| // delete branch locally | |
| git branch -d localBranchName | |
| // delete branch remotely | |
| git push origin --delete remoteBranchName |
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
| git init | |
| git add . | |
| git commit -m "Add existing project files to Git" | |
| git remote add origin https://github.com/cameronmcnz/example-website.git | |
| git push -u -f origin master |
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
| nvm use `cat .nvmrc` |
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
| // Workaround found here: https://github.com/ionic-team/stencil/issues/1090#issuecomment-501124883 | |
| // eslint will shout about using declare global | |
| // but this is keeping me going for now | |
| import { defineCustomElements, JSX as LocalJSX } from '@digi/core/loader'; | |
| import { HTMLAttributes } from 'react'; | |
| type StencilToReact<T> = { | |
| [P in keyof T]?: T[P] & Omit<HTMLAttributes<Element>, 'className'> & { | |
| class?: string; |
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 { DigiButton } from '@digi/core'; | |
| const customElementPromise = customElements.whenDefined('digi-button').then(() => console.log('customEl is defined')); | |
| await customElementPromise; | |
| const myButton:any = document.querySelector('#myButton') | |
| const buttonRef:HTMLButtonElement = await (myButton as DigiButton).afMGetButtonElement().then(res => res); | |
| console.log('buttonRef', buttonRef); |
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
| --- .html | |
| <digi-button #myButton></digi-button> | |
| --- .ts | |
| import { DigiButton } from '@digi/core-angular'; | |
| @ViewChild('myButton') myButtonRef!: DigiButton; | |
| setTimeout(async () => { | |
| const buttonRef:HTMLButtonElement = await this.myButtonRef.afMGetButtonElement().then((res) => res) |
NewerOlder