Class: BlockKit::Layout::RichText::Elements::Link

Inherits:
Base
  • Object
show all
Defined in:
lib/block_kit/layout/rich_text/elements/link.rb

Instance Method Summary collapse

Methods inherited from Base

#==, fix, #fix_validation_errors, #fix_validation_errors!, fixes, inherited, #initialize, inspect, #inspect, #pretty_print, #to_json

Constructor Details

This class inherits a constructor from BlockKit::Base

Instance Method Details

#as_jsonObject



18
19
20
21
22
23
24
25
# File 'lib/block_kit/layout/rich_text/elements/link.rb', line 18

def as_json(*)
  super.merge(
    url: url,
    text: text,
    unsafe: unsafe,
    style: style&.as_json
  ).compact
end