> For the complete documentation index, see [llms.txt](https://knot.gitbook.io/language/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://knot.gitbook.io/language/syntax/overview.md).

# Overview

Syntax of the Knot Language.

## Knots and Bolts

The Knot Language is made up of a number of different layers.

### Modules

[Modules](/language/syntax/syntax/module.md) are the largest element of Knot, they can contain multiple entities such as `view`'s or `state`'s. Modules can export and import entities so that multiple modules can re-use or access code stored in a different module. Modules are referred to using a name that is based on their path from the source directory of your project.

### Entities

[Entities](/language/syntax/syntax/entity.md) are declared within a module and can *only* be declared within a module (functions can technically be created anonymously within a closure by using lambda expressions). Entities include `view` and `func`. Each is used to define an independent, re-usable piece of an application.

### Statements

Certain statements are only available directly within a `module` such as `const` to define static constants and `import` to import from external modules. The `let` statement is only available to define variables within a closure, such as a function body.

### Expressions

As a functional language, we strive to make as much of the language usable as an expression so it can be easily composed. These include simple primitives like booleans and integers as well as binary operations, unary operations, closures and more!

### Primitives

The most basic types you can use to describe data in your application. These include `nil`, `boolean`, `integer`, `float`, `string` and `element`.
