StencilSwiftKit icon indicating copy to clipboard operation
StencilSwiftKit copied to clipboard

Add new increment filter to Numbers

Open FelipeDocil opened this issue 2 years ago • 0 comments

I'm using Sourcery, I can't create my own filters and I've tried many times to increment an Integer, I'd like to ask if it's possible to add this as a new filter for numbers here at StencilSwiftKit (or please help me how I'd achieve this without a new filter)

For context what I'd like to do in Stencil: {{ forloop.counter + 5 }}

Unfortunately this is not yet supported (see for reference: https://github.com/stencilproject/Stencil/issues/117)

I'd like to propose a new filter that would look similar to this: {{ forloop.counter|increment:5 }}

Any thoughts? Again if I can do that with the existing filter please let me know

FelipeDocil avatar Dec 21 '23 18:12 FelipeDocil