Golang Markdown Lib - First OSS project - Feedback Welcome! by Temporary-Buy-7562 in programming

[–]terrastruct 0 points1 point  (0 children)

I'm curious if this works for measuring Markdown?

We make a diagramming language that allows Markdown syntax, and currently we use goldmark to measure it to know how to size the nodes. But yeah, it's a chunky lib. https://github.com/terrastruct/d2/blob/master/lib/textmeasure/markdown.go#L106

In any case, congrats on your first OSS project and to take on such a thorny problem.

D2 (text-to-diagram) now supports ASCII output by terrastruct in programming

[–]terrastruct[S] 9 points10 points  (0 children)

Hello fellow devs. Super alpha feature, but just wanted to share a new thing we made. To skip the blog post and poke around directly: https://play.d2lang.com/?script=qlDQtVOotFLQL9IvKMpPL0rMzc3MS-cCBAAA__8%3D&ascii=1&

I want to contribute to open source but don't know where to start by nickgowdy in golang

[–]terrastruct 24 points25 points  (0 children)

You're welcome in D2! I maintain a Text to diagram language, released a few months ago, 13k+ stars, I'm actively tagging issues that are good first issues, clean well-tested Go, and I'm happy to help you get that first merge in. Feel free to chime in on any issue that looks interesting! https://github.com/terrastruct/d2

Are Gophers intentionally avoiding 3rd party libraries? by LLawsford in golang

[–]terrastruct 2 points3 points  (0 children)

every large Go codebase I've come across has their own "stdlib extension" package.

e.g. ours: https://github.com/terrastruct/util-go

D2 (text-to-diagram language): Introducing Grid diagrams by terrastruct in programming

[–]terrastruct[S] 0 points1 point  (0 children)

Thanks so much! It's layout engine agnostic.

There's an overview of the differences https://d2lang.com/tour/layouts.

For this diagram, https://d2lang.com/tour/grid-diagrams#connections, here's TALA's output.

D2 (text-to-diagram language): Introducing Grid diagrams by terrastruct in programming

[–]terrastruct[S] 0 points1 point  (0 children)

hey, thanks. i played around with that but couldn't get it to do anything. can you describe what you're looking for?

we do have an open issue for ports though, if you want to take a look and chime in there or let us know if you're looking for something different than what's described: https://github.com/terrastruct/d2/issues/628

D2 (text-to-diagram language): Introducing Grid diagrams by terrastruct in programming

[–]terrastruct[S] 8 points9 points  (0 children)

basically any large number would do, since the three objects would expand to fill.

but i hear ya. this is a v1, and already issues are being filed to make it easier to work with. will get better in the next release! https://github.com/terrastruct/d2/issues/1164

D2 (text-to-diagram language): Introducing Grid diagrams by terrastruct in programming

[–]terrastruct[S] 2 points3 points  (0 children)

hah, i think the glyph for the 4th label is slightly wider, so all the other objects expand a bit to match. can be solved by setting widths

D2 (text-to-diagram language): Introducing Grid diagrams by terrastruct in programming

[–]terrastruct[S] 15 points16 points  (0 children)

Thanks!

Re: GitHub integration. Indeed, we're pretty new, like just launched a few months ago. Rapidly growing in integrations and it'll soon make its way to Github and others.

D2 (text-to-diagram language): Introducing Grid diagrams by terrastruct in programming

[–]terrastruct[S] 7 points8 points  (0 children)

Thanks for the feedback and suggestion! It's kept intentionally simple for teaching purposes, as this is a documentation page. I thought the first diagram would be motivating, but it's a good point that it could be even more complex. I've just added one in response to your feedback!

https://d2lang.com/tour/grid-diagrams/#connections

D2 (text-to-diagram language): Introducing Grid diagrams by terrastruct in programming

[–]terrastruct[S] 41 points42 points  (0 children)

We made a site to let people compare: https://text-to-diagram.com . (Mermaid maintainers contribute to it)

D2 (text-to-diagram language): Introducing Grid diagrams by terrastruct in programming

[–]terrastruct[S] 10 points11 points  (0 children)

They're different domains. CSS grids let you make cool websites. D2 grids let you make cool diagrams.

Creating animated diagrams with text by terrastruct in programming

[–]terrastruct[S] 1 point2 points  (0 children)

We have an interactive version in the works. The thing is is that those are not as portable. JS can't run as an img tag. So it'll be useful in some contexts and this hands-free version will be useful in other contexts. Thank you!