0
이상한 점은 발견구글 드라이브 API를 초기화 방법 변경 데이터
var settings = {
apiKey:"[api key]",
client_id:"XXX-59qgl58th06ft9s160cnp28j7a3uunte.apps.googleusercontent.com",
discoveryDocs:["https://www.googleapis.com/discovery/v1/apis/drive/v3/rest"],
folder_id:"0B3vR4cBcxn4odVNTa0VjSmNab3M",
redirect_uris:"http://localhost:8000",
scope:"https://www.googleapis.com/auth/drive"
};
console.log(settings); //checked before init
gapi.load('client:auth2', function(){
gapi.client.init(
settings
);
console.log(settings); //after init
inits GAPI 후에는에 설정 값 변경 :
client_id:"XXXX-59qgl58th06ft9s160cnp28j7a3uunte.apps.googleusercontent.com"
cookie_policy:"single_host_origin"
scope:"https://www.googleapis.com/auth/drive"
이유를 가져올 수 없습니다를! 설정을 가져 와서 계속 진행하면됩니다. 감사합니다
개체에 액세스하면 변경됩니까? 왜? 그러한 행동에 대해 들어 본 적이 없다. – aleXela
왜 라이브러리가 arg를 직접 변경하는지에 대한 구체적인 이유는 알 수 없다. 그러나 나는이 동작에별로 놀라지 않습니다. 또한이 설정을 간단한 설정 개체로 처리 할 것이라고 기대하지 않습니다. 객체 복제로 변경되지 않았습니까? –