mirror of
https://github.com/gohugoio/hugoDocs.git
synced 2025-09-09 18:54:50 -04:00
Update uniq function example (#1963)
This commit is contained in:
parent
686a65cf69
commit
6cc9ebdfd8
@ -2,24 +2,17 @@
|
||||
title: uniq
|
||||
linktitle: uniq
|
||||
description: Takes in a slice or array and returns a slice with duplicate elements removed.
|
||||
date: 2017-02-01
|
||||
publishdate: 2017-02-01
|
||||
lastmod: 2017-02-01
|
||||
categories: [functions]
|
||||
menu:
|
||||
docs:
|
||||
parent: "functions"
|
||||
parent: functions
|
||||
keywords: [multilingual,i18n,urls]
|
||||
signature: ["uniq SET"]
|
||||
workson: []
|
||||
hugoversion:
|
||||
relatedfuncs: []
|
||||
deprecated: false
|
||||
signature: [uniq SET]
|
||||
aliases: []
|
||||
---
|
||||
|
||||
|
||||
```
|
||||
{{ uniq (slice 1 2 3 2) }}
|
||||
{{ slice 1 2 3 2 | uniq }}
|
||||
<!-- both return [1 2 3] -->
|
||||
{{ slice 1 3 2 1 | uniq }} --> [1 3 2]
|
||||
|
||||
```
|
||||
|
Loading…
x
Reference in New Issue
Block a user