fix: Remove missed mentions of rawType (#875)

This commit is contained in:
traxys 2024-01-02 00:26:41 +01:00 committed by GitHub
parent 4d14c098b6
commit 8b8a1c0f4b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 5 additions and 5 deletions

View file

@ -74,7 +74,7 @@ There are a number of helpers to help you correctly implement them:
- `helpers.mkPlugin`: This helper is useful for simple plugins that are configured through (vim) global variables.
- `helpers.defaultNullOpts.{mkBool,mkInt,mkStr,...}`: This family of helpers takes a default value and a description, and sets the Nix default to `null`. These are the main functions you should use to define options.
- `helpers.defaultNullOpts.mkNullable`: This takes a type, a default and a description. This is useful for more complex options.
- `helpers.rawType`: A type to represent raw lua code. The values are of the form `{ __raw = "<code>";}`. This should not be used if the option can only be raw lua code, `mkStr` should be used in this case.
- `helpers.nixvimTypes.rawLua`: A type to represent raw lua code. The values are of the form `{ __raw = "<code>";}`. This should not be used if the option can only be raw lua code, `mkLua`/`mkLuaFn` should be used in this case.
You will then need to map the Nix options to lua code. This can be done through `helpers.toLuaObject`. This function takes a Nix expression, and converts it to a lua string.

View file

@ -371,7 +371,7 @@ with lib; rec {
in
{
rawLua = mkOptionType {
name = "rawType";
name = "rawLua";
description = "raw lua code";
descriptionClass = "noun";
merge = mergeEqualOption;

View file

@ -214,7 +214,7 @@ in {
''
''
Actions to be triggered for specified keybindings. It can take either action name i.e `toggle_preview`
Or it can a `rawType`.
Or it can a `rawLua`.
'';
lsp = {

View file

@ -84,7 +84,7 @@ in {
)
''
The type of `content` depends on the secton `type`:
- "text" -> a list of strings or a function (`rawType`) that requires a function that returns a table of strings
- "text" -> a list of strings or a function (`rawLua`) that requires a function that returns a table of strings
- "mapping" -> a list of list of strings in the format:
```nix
[

View file

@ -77,7 +77,7 @@ in {
after cursor.
This is either:
- a `rawType` value (`action.__raw = "function() foo end";`).
- a `rawLua` value (`action.__raw = "function() foo end";`).
- a string. In this case, Nixvim will automatically interpret it as a builtin yanky
action.
Example: `action = "put('p')";` will translate to