Skip to content

Commit

Permalink
Improve getting started
Browse files Browse the repository at this point in the history
  • Loading branch information
kalashnikovisme authored Jan 19, 2025
1 parent 852dac3 commit be7b906
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,29 @@ bundle add tramway view_component

## Usage

### Basic Example

**Step 1**

*config/initializers/tramway.rb*
```
Tramway.configure do |config|
config.entities = [ :user ] # use any model you want instead
end
```

**Step 2**

Run your server

```
bundle exec rails s
```

**Step 3**

Open [http://localhost:3000](http://localhost:3000)

### Tramway Entities

Tramway is an entity-based framework. **Entity** is the class on whose objects actions be applied: _index, show, create, update, and destroy_. Tramway will support numerous classes as entities. For now, Entity could be only **ActiveRecord::Base** class.
Expand Down

0 comments on commit be7b906

Please sign in to comment.