{"action":"created","issue":{"url":"https://api.github.com/repos/frontendbr/forum/issues/1211","repository_url":"https://api.github.com/repos/frontendbr/forum","labels_url":"https://api.github.com/repos/frontendbr/forum/issues/1211/labels{/name}","comments_url":"https://api.github.com/repos/frontendbr/forum/issues/1211/comments","events_url":"https://api.github.com/repos/frontendbr/forum/issues/1211/events","html_url":"https://github.com/frontendbr/forum/issues/1211","id":360008137,"node_id":"MDU6SXNzdWUzNjAwMDgxMzc=","number":1211,"title":"[Vue.js] Como manter uma variável global ao atualizar a página?","user":{"login":"kvnol","id":3299130,"node_id":"MDQ6VXNlcjMyOTkxMzA=","avatar_url":"https://avatars1.githubusercontent.com/u/3299130?v=4","gravatar_id":"","url":"https://api.github.com/users/kvnol","html_url":"https://github.com/kvnol","followers_url":"https://api.github.com/users/kvnol/followers","following_url":"https://api.github.com/users/kvnol/following{/other_user}","gists_url":"https://api.github.com/users/kvnol/gists{/gist_id}","starred_url":"https://api.github.com/users/kvnol/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kvnol/subscriptions","organizations_url":"https://api.github.com/users/kvnol/orgs","repos_url":"https://api.github.com/users/kvnol/repos","events_url":"https://api.github.com/users/kvnol/events{/privacy}","received_events_url":"https://api.github.com/users/kvnol/received_events","type":"User","site_admin":false},"labels":[{"id":319789303,"node_id":"MDU6TGFiZWwzMTk3ODkzMDM=","url":"https://api.github.com/repos/frontendbr/forum/labels/JavaScript","name":"JavaScript","color":"fbca04","default":false},{"id":371544136,"node_id":"MDU6TGFiZWwzNzE1NDQxMzY=","url":"https://api.github.com/repos/frontendbr/forum/labels/[D%C3%BAvida]","name":"[Dúvida]","color":"fef2c0","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":11,"created_at":"2018-09-13T18:14:34Z","updated_at":"2018-09-25T14:09:10Z","closed_at":null,"author_association":"CONTRIBUTOR","body":"e aí!\r\n\r\n> olha, não sei se essa é a melhor forma de se fazer isso porque sou um mero recortador de layout se aventurando no Vue, mas deem sugestões (kkk)\r\n\r\nPessoal, estou trabalhando com Vue no Laravel, consumindo uma API com Axios, onde envio o CPF através do input numa tela de login. Se a API encontra o CPF (status 200), ela redireciona para a tela principal. Só que, ao atualizar a página, eu perco esse CPF que eu precisaria para renderizar as informações do cliente.\r\n\r\nEu teria que usar Vuex? O que seria o melhor a fazer?"},"comment":{"url":"https://api.github.com/repos/frontendbr/forum/issues/comments/424358277","html_url":"https://github.com/frontendbr/forum/issues/1211#issuecomment-424358277","issue_url":"https://api.github.com/repos/frontendbr/forum/issues/1211","id":424358277,"node_id":"MDEyOklzc3VlQ29tbWVudDQyNDM1ODI3Nw==","user":{"login":"kvnol","id":3299130,"node_id":"MDQ6VXNlcjMyOTkxMzA=","avatar_url":"https://avatars1.githubusercontent.com/u/3299130?v=4","gravatar_id":"","url":"https://api.github.com/users/kvnol","html_url":"https://github.com/kvnol","followers_url":"https://api.github.com/users/kvnol/followers","following_url":"https://api.github.com/users/kvnol/following{/other_user}","gists_url":"https://api.github.com/users/kvnol/gists{/gist_id}","starred_url":"https://api.github.com/users/kvnol/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kvnol/subscriptions","organizations_url":"https://api.github.com/users/kvnol/orgs","repos_url":"https://api.github.com/users/kvnol/repos","events_url":"https://api.github.com/users/kvnol/events{/privacy}","received_events_url":"https://api.github.com/users/kvnol/received_events","type":"User","site_admin":false},"created_at":"2018-09-25T14:09:10Z","updated_at":"2018-09-25T14:09:10Z","author_association":"CONTRIBUTOR","body":"Refatorei o código passando o JSON de retorno direto para o sessionStorage, aí não preciso ficar fazendo Ajax em todos os componentes para retornar o `response.data`, como estava sendo com o CPF/CNPJ como parâmetro de URL.\r\n\r\nTá rodando lindo. Valeu, galera! :heart: "}}
{"actor":{"display_login":"kvnol"}}