package atom
Import Path
golang.org/x/net/html/atom (on go.dev)
Dependency Relation
imports 0 packages, and imported by one package
Involved Source Files
Package atom provides integer codes (also known as atoms) for a fixed set of
frequently occurring HTML strings: tag names and attribute keys such as "p"
and "id".
Sharing an atom's name between all elements with the same tag can result in
fewer string allocations when tokenizing and parsing HTML. Integer
comparisons are also generally faster than string comparisons.
The value of an atom's particular code is not guaranteed to stay the same
between versions of this package. Neither is any ordering guaranteed:
whether atom.H1 < atom.H2 may also change. The codes are not guaranteed to
be dense. The only guarantees are that e.g. looking up "div" will yield
atom.Div, calling atom.Div.String will return "div", and atom.Div != 0.
table.go
Package-Level Type Names (only one)
Atom is an integer code for a string. The zero value maps to "".
String returns the atom's name.
Atom : fmt.Stringer
Atom : github.com/ChrisTrenkamp/goxpath/tree.Result
func Lookup(s []byte) Atom
const A
const Abbr
const Accept
const AcceptCharset
const Accesskey
const Acronym
const Action
const Address
const Align
const Allowfullscreen
const Allowpaymentrequest
const Allowusermedia
const Alt
const Annotation
const AnnotationXml
const Applet
const Area
const Article
const As
const Aside
const Async
const Audio
const Autocomplete
const Autofocus
const Autoplay
const B
const Base
const Basefont
const Bdi
const Bdo
const Bgsound
const Big
const Blink
const Blockquote
const Body
const Br
const Button
const Canvas
const Caption
const Center
const Challenge
const Charset
const Checked
const Cite
const Class
const Code
const Col
const Colgroup
const Color
const Cols
const Colspan
const Command
const Content
const Contenteditable
const Contextmenu
const Controls
const Coords
const Crossorigin
const Data
const Datalist
const Datetime
const Dd
const Default
const Defer
const Del
const Desc
const Details
const Dfn
const Dialog
const Dir
const Dirname
const Disabled
const Div
const Dl
const Download
const Draggable
const Dropzone
const Dt
const Em
const Embed
const Enctype
const Face
const Fieldset
const Figcaption
const Figure
const Font
const Footer
const For
const ForeignObject
const Foreignobject
const Form
const Formaction
const Formenctype
const Formmethod
const Formnovalidate
const Formtarget
const Frame
const Frameset
const H1
const H2
const H3
const H4
const H5
const H6
const Head
const Header
const Headers
const Height
const Hgroup
const Hidden
const High
const Hr
const Href
const Hreflang
const Html
const HttpEquiv
const I
const Icon
const Id
const Iframe
const Image
const Img
const Input
const Inputmode
const Ins
const Integrity
const Is
const Isindex
const Ismap
const Itemid
const Itemprop
const Itemref
const Itemscope
const Itemtype
const Kbd
const Keygen
const Keytype
const Kind
const Label
const Lang
const Legend
const Li
const Link
const List
const Listing
const Loop
const Low
const Main
const Malignmark
const Manifest
const Map
const Mark
const Marquee
const Math
const Max
const Maxlength
const Media
const Mediagroup
const Menu
const Menuitem
const Meta
const Meter
const Method
const Mglyph
const Mi
const Min
const Minlength
const Mn
const Mo
const Ms
const Mtext
const Multiple
const Muted
const Name
const Nav
const Nobr
const Noembed
const Noframes
const Nomodule
const Nonce
const Noscript
const Novalidate
const Object
const Ol
const Onabort
const Onafterprint
const Onautocomplete
const Onautocompleteerror
const Onauxclick
const Onbeforeprint
const Onbeforeunload
const Onblur
const Oncancel
const Oncanplay
const Oncanplaythrough
const Onchange
const Onclick
const Onclose
const Oncontextmenu
const Oncopy
const Oncuechange
const Oncut
const Ondblclick
const Ondrag
const Ondragend
const Ondragenter
const Ondragexit
const Ondragleave
const Ondragover
const Ondragstart
const Ondrop
const Ondurationchange
const Onemptied
const Onended
const Onerror
const Onfocus
const Onhashchange
const Oninput
const Oninvalid
const Onkeydown
const Onkeypress
const Onkeyup
const Onlanguagechange
const Onload
const Onloadeddata
const Onloadedmetadata
const Onloadend
const Onloadstart
const Onmessage
const Onmessageerror
const Onmousedown
const Onmouseenter
const Onmouseleave
const Onmousemove
const Onmouseout
const Onmouseover
const Onmouseup
const Onmousewheel
const Onoffline
const Ononline
const Onpagehide
const Onpageshow
const Onpaste
const Onpause
const Onplay
const Onplaying
const Onpopstate
const Onprogress
const Onratechange
const Onrejectionhandled
const Onreset
const Onresize
const Onscroll
const Onsecuritypolicyviolation
const Onseeked
const Onseeking
const Onselect
const Onshow
const Onsort
const Onstalled
const Onstorage
const Onsubmit
const Onsuspend
const Ontimeupdate
const Ontoggle
const Onunhandledrejection
const Onunload
const Onvolumechange
const Onwaiting
const Onwheel
const Open
const Optgroup
const Optimum
const Option
const Output
const P
const Param
const Pattern
const Picture
const Ping
const Placeholder
const Plaintext
const Playsinline
const Poster
const Pre
const Preload
const Progress
const Prompt
const Public
const Q
const Radiogroup
const Rb
const Readonly
const Referrerpolicy
const Rel
const Required
const Reversed
const Rows
const Rowspan
const Rp
const Rt
const Rtc
const Ruby
const S
const Samp
const Sandbox
const Scope
const Scoped
const Script
const Seamless
const Section
const Select
const Selected
const Shape
const Size
const Sizes
const Slot
const Small
const Sortable
const Sorted
const Source
const Spacer
const Span
const Spellcheck
const Src
const Srcdoc
const Srclang
const Srcset
const Start
const Step
const Strike
const Strong
const Style
const Sub
const Summary
const Sup
const Svg
const System
const Tabindex
const Table
const Target
const Tbody
const Td
const Template
const Textarea
const Tfoot
const Th
const Thead
const Time
const Title
const Tr
const Track
const Translate
const Tt
const Type
const Typemustmatch
const U
const Ul
const Updateviacache
const Usemap
const Value
const Var
const Video
const Wbr
const Width
const Workertype
const Wrap
const Xmp
Package-Level Functions (total 2)
Lookup returns the atom whose name is s. It returns zero if there is no
such atom. The lookup is case sensitive.
String returns a string whose contents are equal to s. In that sense, it is
equivalent to string(s) but may be more efficient.
Package-Level Constants (total 368)
const AcceptCharset Atom = 6670 const Allowfullscreen Atom = 133135 const Allowpaymentrequest Atom = 49427 const Allowusermedia Atom = 56590 const Annotation Atom = 117002 const AnnotationXml Atom = 117006 const Autocomplete Atom = 161804 const Blockquote Atom = 100106 const Contenteditable Atom = 363279 const Crossorigin Atom = 129803 const Figcaption Atom = 142858 const ForeignObject Atom = 152589 const Foreignobject Atom = 155917 const Formaction Atom = 159242 const Formenctype Atom = 166155 const Formmethod Atom = 173066 const Formnovalidate Atom = 175630 const Formtarget Atom = 180234 const Malignmark Atom = 45066 const Mediagroup Atom = 58890 const Novalidate Atom = 176650 const Onafterprint Atom = 144908 const Onautocomplete Atom = 161294 const Onautocompleteerror Atom = 161299 const Onauxclick Atom = 401162 const Onbeforeprint Atom = 433677 const Onbeforeunload Atom = 452366 const Oncanplaythrough Atom = 85264 const Oncuechange Atom = 235275 const Ondblclick Atom = 239370 const Ondragenter Atom = 244235 const Ondragexit Atom = 247050 const Ondragleave Atom = 253707 const Ondragover Atom = 256522 const Ondragstart Atom = 259083 const Ondurationchange Atom = 267024 const Onhashchange Atom = 277772 const Onkeypress Atom = 289546 const Onlanguagechange Atom = 298256 const Onloadeddata Atom = 302348 const Onloadedmetadata Atom = 307216 const Onloadstart Atom = 315147 const Onmessageerror Atom = 317966 const Onmousedown Atom = 321547 const Onmouseenter Atom = 324364 const Onmouseleave Atom = 327436 const Onmousemove Atom = 330507 const Onmouseout Atom = 333322 const Onmouseover Atom = 336651 const Onmousewheel Atom = 343052 const Onpagehide Atom = 350474 const Onpageshow Atom = 357130 const Onpopstate Atom = 371978 const Onprogress Atom = 374538 const Onratechange Atom = 379916 const Onrejectionhandled Atom = 382994 const Onsecuritypolicyviolation Atom = 395289 const Ontimeupdate Atom = 16396 const Onunhandledrejection Atom = 429076 const Onvolumechange Atom = 439054 const Placeholder Atom = 78091 const Playsinline Atom = 81931 const Radiogroup Atom = 778 const Referrerpolicy Atom = 250126 const Spellcheck Atom = 291850 const Typemustmatch Atom = 167949 const Updateviacache Atom = 17934 const Workertype Atom = 465930
![]() |
The pages are generated with Golds v0.6.7. (GOOS=linux GOARCH=amd64) Golds is a Go 101 project developed by Tapir Liu. PR and bug reports are welcome and can be submitted to the issue list. Please follow @Go100and1 (reachable from the left QR code) to get the latest news of Golds. |