
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
get-notion-object-title
Advanced tools
The Notion API does not provide a simple way to retrieve the title of an object. This module provides you with a simple API where you can pass in a Notion Object and receive a human readable string.
npm i get-notion-object-title
import getNotionObjectTitle from 'get-notion-object-title';
getNotionObjectTitle(yourBlock); // returns "Human readable block title"
If you already have a way to handle icons and would like to only get the text, you can disable the emojis by passing in an option.
getNotionObjectTitle(yourBlock, { emoji: false }); // returns "Human readable block title"
The getNotionObjectTitle takes a Notion object as input and returns a string.
Depending on the type of the object there are some rules that are applied.
If the page has any of the following properties they will be used and they do exclude each other:
The database uses the top level title attribute.
The remaining blocks are converted to plain text using the rich text items.
Unless otherwise specified in the source:
The code is licensed under the MIT Copyright (c) 2023, Alexander Alemayhu.
FAQs
get human readable names from Notion objects.
We found that get-notion-object-title 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.

Security News
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.