Skip to content

View Circuit JSON in an assembly view (for quickly seeing part placements and rotations)

License

Notifications You must be signed in to change notification settings

AnasSarkiz/assembly-viewer

 
 

Repository files navigation

@tscircuit/assembly-viewer

React component for viewing Circuit JSON or tscircuit as a assembly diagram

import { AssemblyViewer } from "@tscircuit/assembly-viewer"

export default () => (
  <AssemblyViewer
    circuitJson={renderToCircuitJson(
      <board width="10mm" height="10mm">
        <resistor name="R1" resistance={1000} schX={-2} />
        <capacitor name="C1" capacitance="1uF" schX={2} />
        <trace from=".R1 .pin2" to=".C1 .pin1" />
      </board>
    )}
  />
)

References

  • This repo is heavily based on the schematic-viewer repo, if you're trying to add functionality you may want to reference that repo which is a bit more advanced

About

View Circuit JSON in an assembly view (for quickly seeing part placements and rotations)

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • TypeScript 88.5%
  • HTML 6.1%
  • JavaScript 5.4%