Skip to content

Instantly share code, notes, and snippets.

@wilmoore
Last active April 5, 2023 07:14
Show Gist options
  • Save wilmoore/ee002b397dcbd5aa5b764f037db6a239 to your computer and use it in GitHub Desktop.
Save wilmoore/ee002b397dcbd5aa5b764f037db6a239 to your computer and use it in GitHub Desktop.
Income Sources :: uniqode

Income Sources :: uniqode

⪼ Made with 💜 by realpolyglot.dev

ūniqöde logo designer.

ūniqöde

const parsed = parse(`
<svg
  version="1.1"
  id="Won Sign (U+20A9): God First"
  viewBox="0 0 350 350"
  width="350"
  height="350"
  text-anchor="middle"
  font-family="Times New Roman"
  style="background-color: transparent important!;"
  xmlns="http://www.w3.org/2000/svg"
  >
  <circle
    id="badge"
    fill="none"
    fill-opacity="0"
    stroke="#000"
    stroke-width="21"
    shape-rendering="geometricPrecision"
    cx="175"
    cy="175"
    r="155"
    />
  <text
    id="uniqode"
    font-size="15em"
    fill="#000"
    x="174"
    y="255"
    dy="0"
    >₩</text>
  <text
    id="name"
    font-size="1.5em"
    fill="#000"
    x="175"
    y="290"
    dy="0"
    >Wil Moore III</text>
  <text
    id="domain"
    font-size="0.95em"
    font-style="italic"
    fill="#000"
    x="175"
    y="305"
    dy="0"
    ></text>
</svg>
`);

Inspiration

Notes

  • I can query the svg file directly
  • copy template (default value)
  • Find by path (full name) `parsed.children[0].children[2].children[0].value
  • All elements at same level so query by id root: parsed.children[0].children .find: ((element) => element.poperties.id === "badge" (string)
  • dependencies npm install svg-parser --save or yarn add svg-parser
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment