You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We just looked at an alternative gem that generates Mermaid ER diagrams:rails-mermaid_erd - and noticed it generates far more typical ER diagrams.
The main difference seems to be that rails-erd uses the Mermaid type classDiagram, not erDiagram -- quite possibly this matches better with the old code for dot-diagrams?
At any rate, there seems to be potential to improve Mermaid output considerably, going from:
classDiagram
direction RL
class `Course`
`Course` : +string tag
`Course` : +string name
class `CourseType`
`CourseType` : +string name
`CourseType` --> `Course`
Loading
to:
erDiagram
Course {
integer id PK
string tag
string name
integer course_type_id FK
datetime created_at
datetime updated_at
}
CourseType {
integer id PK
string name
datetime created_at
datetime updated_at
}
Course }o--|| CourseType : "Course of type CourseType"
We just looked at an alternative gem that generates Mermaid ER diagrams:rails-mermaid_erd - and noticed it generates far more typical ER diagrams.
The main difference seems to be that
rails-erd
uses the Mermaid typeclassDiagram
, noterDiagram
-- quite possibly this matches better with the old code for dot-diagrams?At any rate, there seems to be potential to improve Mermaid output considerably, going from:
to:
erDiagrams are documented at:
https://mermaid.js.org/syntax/entityRelationshipDiagram.html
The text was updated successfully, but these errors were encountered: