Skip to content

Commit 0ac8839

Browse files
committed
Update README.md
1 parent 407f0ff commit 0ac8839

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
# Positioning
22

3+
[![Tests](https://github.com/brendon/positioning/actions/workflows/main.yml/badge.svg)](https://github.com/brendon/positioning/actions/workflows/main.yml)
4+
35
The aim of this gem is to allow you to easily position Active Record model instances within a scope of your choosing. In an ideal world this gem will give your model instances sequential integer positions beginning with `1`. Attempts are made to make all changes within a transaction so that position integers remain consistent. To this end, directly assigning a position is discouraged, instead you can move items by declaring an item's prior or subsequent item in the list and your item will be moved to be relative to that item.
46

57
Positioning supports multiple lists per model with global, simple, and complex scopes.
@@ -274,7 +276,7 @@ If you must position child models separately, scope their position by the `type`
274276

275277
```rb
276278
positioned on: [:type]
277-
```
279+
```
278280

279281
## Concurrency
280282

0 commit comments

Comments
 (0)