# Templates

## Make a new Template <a href="#new" id="new"></a>

{% code lineNumbers="true" %}

```javascript
const template = new Template({
id:"",
name:"",
password:""
})
```

{% endcode %}

### Parameters

<table><thead><tr><th>Name</th><th>About</th><th>Type</th><th data-type="checkbox">Required</th></tr></thead><tbody><tr><td>template</td><td>The object to base the new Template on.</td><td>Object</td><td>true</td></tr></tbody></table>

## Use Template <a href="#use" id="use"></a>

{% code lineNumbers="true" %}

```javascript
data.create('tag', template.use('123456',"John","password"))
```

{% endcode %}

### Parameters

The parameters of this function are what will be set to the value of the keys in order.

**Example**: the parameter`John` will be the value of `name`since they are both in the second position.

## Full code example <a href="#example" id="example"></a>

{% code lineNumbers="true" %}

```javascript
const data = new Dubnium('json' /* Templates are JSON only */,false) 

const template = new Template({ 
id:"",
name:"",
password:""
})

data.create('tag', template.use('123456',"John","password"))
```

{% endcode %}
