
Research
Two Malicious Rust Crates Impersonate Popular Logger to Steal Wallet Keys
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.
inquirer-table
Advanced tools
A table prompt for Inquirer.js.
Interactive table component for command line interfaces.
yarn | npm | pnpm |
---|---|---|
yarn add inquirer-table | npm install inquirer-table | pnpm add inquirer-table |
import { table, type TableColumn } from 'inquirer-table';
interface Post {
userId: number;
id: number;
title: string;
body: string;
}
const posts: Post[] = [
{
userId: 1,
id: 1,
title:
'sunt aut facere repellat provident occaecati excepturi optio reprehenderit',
body: 'quia et suscipit\nsuscipit recusandae consequuntur expedita et cum\nreprehenderit molestiae ut ut quas totam\nnostrum rerum est autem sunt rem eveniet architecto'
}
];
const columns: TableColumn<Post>[] = [
{
header: 'ID',
accessorKey: 'id'
},
{
header: 'User ID',
accessorKey: 'userId'
},
{
header: 'Title',
accessorKey: 'title'
},
{
header: 'Body',
accessorKey: 'body'
}
];
const answer = await table({
data: posts,
columns
});
Property | Type | Required | Description |
---|---|---|---|
data | TableItem[] | Yes | Data to be shown in the table. |
columns | TableColumn<TableItem>[] | Yes | Table columns. |
pageSize | number | No | Page size for pagination. Defaults to 5 . |
multiple | boolean | No | If true , multiple selection is allowed. Defaults to false . |
selectable | boolean | No | If true , table rows become selectable. Defaults to false . |
abortController | AbortController | No | If an AbortController is provided, the prompt can be cancelled by pressing backspace . Canceling Prompt |
tableOptions | Omit<CliTable.TableConstructorOptions, 'head' | 'colWidths' | 'colAligns'> | No | cli-table3 options. |
renderHeader | (params: UseTablePaginationReturn & UseCliTableBaseOptions<TableItem>) => string | null | undefined | No | Render the table header. |
renderFooter | (params: UseTablePaginationReturn & UseCliTableBaseOptions<TableItem>) => string | null | undefined | No | Render the table footer. |
renderFigureCell | (params: RenderFigureCellParams) => CliTable.Cell | No | Render figure cell. |
renderActiveCell | (value: CliTable.CellValue) => CliTable.CellValue | No | Render the cell where the pointer is active. |
renderSelectedCell | (value: CliTable.CellValue) => CliTable.CellValue | No | Render the selected cell. |
renderUnSelectedCell | (value: CliTable.CellValue) => CliTable.CellValue | No | Render the unselected cell. |
FAQs
A table prompt for Inquirer.js.
We found that inquirer-table demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.
Research
A malicious package uses a QR code as steganography in an innovative technique.
Research
/Security News
Socket identified 80 fake candidates targeting engineering roles, including suspected North Korean operators, exposing the new reality of hiring as a security function.