mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 06:07:34 +00:00
LibWeb: Use HTML::AttributeNames::foo instead of FlyString("foo")
To avoid the costly instantiation of FlyStrings whenever we're looking up attributes, use the premade HTML::AttributeNames globals. :^)
This commit is contained in:
parent
ff55d00261
commit
2149820260
16 changed files with 71 additions and 43 deletions
|
@ -35,7 +35,7 @@ public:
|
|||
HTMLElement(Document&, const FlyString& tag_name);
|
||||
virtual ~HTMLElement() override;
|
||||
|
||||
String title() const { return attribute("title"); }
|
||||
String title() const { return attribute(HTML::AttributeNames::title); }
|
||||
|
||||
private:
|
||||
virtual bool is_html_element() const final { return true; }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue