fix: filter_on is not a method somehow
parent
2a0a1629d5
commit
edcceb144c
10
README.md
10
README.md
|
@ -51,7 +51,12 @@ Here's a basic example of how to use tsql.nvim:
|
|||
local ts = require('tsql')
|
||||
-- ts.t(<buf_match>, <ts_query>, <sink>)
|
||||
-- Matches all strings in our neovim workspace.
|
||||
ts.t(ts.buf_match.any(), ts.ts_query.from_scm("string"), ts.sink_by.print())
|
||||
ts.t(ts.buf_match.any(), ts.ts_query.from_scm("string"), ts.sink_by.print()):do_nvim()
|
||||
```
|
||||
|
||||
Here's the same thing in a one-liner
|
||||
```lua
|
||||
:lua local ts = require('tsql'); ts.t(ts.buf_match.any(), ts.ts_query.from_scm("string"), ts.sink_by.print()):do_nvim()
|
||||
```
|
||||
|
||||
## Installation
|
||||
|
@ -66,7 +71,8 @@ Don't forget to run `:PlugInstall` to actually install the plugin.
|
|||
|
||||
## Configuration
|
||||
|
||||
To configure tsql.nvim, you can provide a configuration table to the `M.setup` function. Here's an example:
|
||||
To configure tsql.nvim, you can provide a configuration table to the `M.setup` function.
|
||||
Here's an example (and is the default configuration):
|
||||
|
||||
```lua
|
||||
local tsql = require('tsql')
|
||||
|
|
|
@ -150,7 +150,7 @@ end
|
|||
---NOTE: requires nvim runtime
|
||||
function M.Tsql:q_nodes()
|
||||
return self.codeql:find_nodes(
|
||||
self.buf_match:filter_on(M.nvim_get_qbufs())
|
||||
self.buf_match.filter_on(self.buf_match, M.nvim_get_qbufs())
|
||||
)
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue