Listary 6 plugin example.
- put the directory inside the plugin folder.
cd %AppData%\Listary\UserProfile\Extensions
git clone https://github.com/378978764/listary-plugin-example.git
- restart listary.
Use Javascript as the development language.
This is the config file.
{
// unuque id
"guid": "F86966A8-24A9-46A0-BAEA-11E861A5C2C4",
// extension name
"name": "dict",
// extension icon
"icon": "language.png",
// keyword to trigger it
"defaultKeyword": "yd"
}
This is the entry of the extension.
async function search(query) {
return [
{
title: 'title',
subtitle: 'subtitle',
execution: [
{
type: 'OpenUrl',
url: 'http://baidu.com'
}
]
}
]
}
Following fields are supported:
- title: the title
- subtitle: the subtitle
- execution: actions when user choose item.
This is an example of Youdao Dict.