{"json_modified": "2015-11-11T03:10:47.297475", "slug": "Web/Events/popstate", "tags": [], "locale": "pt-BR", "title": "popstate", "translations": [{"title": "popstate", "url": "/en-US/docs/Web/Events/popstate", "tags": [], "summary": "The popstate
event is fired when the active history entry changes. If the history entry being activated was created by a call to history.pushState()
or was affected by a call to history.replaceState()
, the popstate
event's state
property contains a copy of the history entry's state object.", "localization_tags": [], "locale": "en-US", "last_edit": "2015-08-13T02:25:44", "review_tags": []}, {"title": "popstate", "url": "/zh-CN/docs/Web/Events/popstate", "tags": [], "summary": "\u5f53\u524d\u6d3b\u52a8\u5386\u53f2\u9879(history entry)\u6539\u53d8\u4f1a\u89e6\u53d1popstate\u4e8b\u4ef6\u3002\u8c03\u7528history.pushState()
\u521b\u5efa\u65b0\u7684\u5386\u53f2\u9879(history entry)\uff0c\u6216\u8c03\u7528history.replaceState()\u66ff\u6362\u65b0\u7684\u5386\u53f2\u9879
(history entry)\uff0c\u90a3\u4e48popstate\u4e8b\u4ef6\u7684state\u5c5e\u6027\u4f1a\u5305\u542b\u5386\u53f2\u9879(history entry)\u72b6\u6001\u5bf9\u8c61(state object)\u7684\u62f7\u8d1d\u3002", "localization_tags": [], "locale": "zh-CN", "last_edit": "2015-11-09T18:58:40", "review_tags": []}], "modified": "2015-11-11T03:10:46", "label": "popstate", "localization_tags": [], "url": "/pt-BR/docs/Web/Events/popstate", "last_edit": "2015-11-11T03:10:44", "summary": "O evento\u00a0popstate
\u00e9 disparado quando a entrada do\u00a0hist\u00f3rico\u00a0ativa \u00e9 alterado. Se o hist\u00f3rico de entrada a ser ativado for criado por uma chamada\u00a0history.pushState()\u00a0
ou for afetada por uma\u00a0chamada\u00a0history.replaceState(),
\u00a0a\u00a0prorpiedade\u00a0dos eventos popstate
cont\u00e9m uma c\u00f3pia do hist\u00f3rico de entrada do objeto.
\n Note \u00a0que apenas chamando\u00a0history.pushState()
ou\u00a0history.replaceState()
\u00a0n\u00e3o ira disparar um evento\u00a0popstate.\u00a0
O evento popstate
apenas \u00e9 disparado ap\u00f3s uma a\u00e7\u00e3o no navegador como um click no bot\u00e3o de voltar (ou chamando history.back() por javascript
)
\n Navegadores tendem a lidar com o evento popstate\u00a0
diferentemente no carregamento da p\u00e1gina.\u00a0Chrome (anterior vers\u00e3o 34) e\u00a0Safari sempre emitem um evento popstate
no carregamento da p\u00e1gina, mas o Firefox\u00a0n\u00e3o.", "sections": [{"id": "Informa\u00e7\u00e3o_geral", "title": "Informa\u00e7\u00e3o\u00a0geral"}, {"id": "Propriedades", "title": "Propriedades"}, {"id": "Compatiblidade_com_navegadores", "title": "Compatiblidade com navegadores"}, {"id": "Exemplo", "title": "Exemplo"}, {"id": "Eventos_relacionados", "title": "Eventos relacionados"}], "id": 165757, "review_tags": []}