Module: NotionToHtml
- Extended by:
- Dry::Configurable
- Defined in:
- lib/notion_to_html/page.rb,
lib/notion_to_html.rb,
lib/notion_to_html/service.rb,
lib/notion_to_html/version.rb,
lib/notion_to_html/base_page.rb,
lib/notion_to_html/renderers.rb,
lib/notion_to_html/base_block.rb
Overview
The NotionToHtml::BaseBlock class represents a block in a Notion page, handling its attributes and rendering. This class processes the raw data of a block fetched from the Notion API and makes it accessible through various attributes. It also provides methods to render formatted output for different block types like paragraphs, headings, lists, quotes, and media.
Defined Under Namespace
Modules: Renderers Classes: BaseBlock, BasePage, Page, Service
Constant Summary collapse
- VERSION =
The current version of the NotionToHtml gem.
'1.3.1'
Instance Attribute Summary collapse
-
#cache_store ⇒ ActiveSupport::Cache::Store
The cache store used to cache responses from the Notion API.
-
#notion_api_token ⇒ String
The API token used to authenticate requests to the Notion API.
-
#notion_database_id ⇒ String
The database ID in Notion that the module will interact with.
-
#notion_default_max_retries ⇒ Integer
The maximum number of times to retry failed API requests.
-
#notion_default_page_size ⇒ Integer
The default number of records to return per page when making paginated requests.
-
#notion_default_retry_after ⇒ Integer
The number of seconds to wait between retry attempts for failed API requests.
-
#notion_timeout ⇒ Integer
The number of seconds to wait for a response from the Notion API before timing out.
Instance Attribute Details
#cache_store ⇒ ActiveSupport::Cache::Store
Returns The cache store used to cache responses from the Notion API.
49 |
# File 'lib/notion_to_html.rb', line 49 setting :cache_store, default: ActiveSupport::Cache::MemoryStore.new |
#notion_api_token ⇒ String
Returns The API token used to authenticate requests to the Notion API.
16 |
# File 'lib/notion_to_html.rb', line 16 setting :notion_api_token |
#notion_database_id ⇒ String
Returns The database ID in Notion that the module will interact with.
20 |
# File 'lib/notion_to_html.rb', line 20 setting :notion_database_id |
#notion_default_max_retries ⇒ Integer
Returns The maximum number of times to retry failed API requests.
38 |
# File 'lib/notion_to_html.rb', line 38 setting :notion_default_max_retries, default: 5 |
#notion_default_page_size ⇒ Integer
Returns The default number of records to return per page when making paginated requests.
32 |
# File 'lib/notion_to_html.rb', line 32 setting :notion_default_page_size, default: 100 |
#notion_default_retry_after ⇒ Integer
Returns The number of seconds to wait between retry attempts for failed API requests.
44 |
# File 'lib/notion_to_html.rb', line 44 setting :notion_default_retry_after, default: 10 |
#notion_timeout ⇒ Integer
Returns The number of seconds to wait for a response from the Notion API before timing out.
26 |
# File 'lib/notion_to_html.rb', line 26 setting :notion_timeout, default: 30 |