1.0.0 • Published 3 years ago

github-link v1.0.0

Weekly downloads
21
License
MIT
Repository
-
Last release
3 years ago

<script
  src="https://unpkg.com/github-link/dist/esm/github-link.js"
  type="module"
></script>

<github-link url="https://github.com/ivgtr/github-link" />

Demo

demo

Usages

Script tag

  • Set a script tag like this. <script src="https://unpkg.com/github-link/dist/esm/github-link.js" type="module"></script>
  • Call <github-link /> at any place.

Vue

  • Install it with npm i github-link --save
  • Call the loader as follows.
<script>
import { applyPolyfills, defineCustomElements } from 'github-link/loader'

applyPolyfills().then(() => {
  defineCustomElements()
})

export default {
  name: "App"
}
</script>
<templeate>
  <div id="app">
    <github-link url="https://github.com/ivgtr/github-link" />
  </div>
</templeate>

React

  • Install it with npm i github-link --save
  • Call the loader as follows
import { applyPolyfills, defineCustomElements } from 'github-link/loader'

applyPolyfills().then(() => {
  defineCustomElements()
});

export default function App() {
  return (
    <div className="App">
       <github-link url="https://github.com/ivgtr/github-link" />
    </div>
  );
}

Configs

PropertyAttributeDescriptionTypeDefault
modemodeReverse to Lightmode and Darkmode Themes."normal" \| "reverse"'normal'
urlurlThe Github link you want to configure.string'https://github.com/'

License

MIT ©ivgtr

Twitter Follow MIT License Donate