teratail header banner
teratail header banner
質問するログイン新規登録

質問編集履歴

5

脱字

2020/06/03 08:50

投稿

ff7575
ff7575

スコア123

title CHANGED
@@ -1,1 +1,1 @@
1
- firebase.storage() が無い?!。そんなバカな(Nuxt.js)
1
+ ["firebase"].storage is not a function. **。そんなバカなありえない(Nuxt.js)
body CHANGED
File without changes

4

内容修正

2020/06/03 08:50

投稿

ff7575
ff7575

スコア123

title CHANGED
File without changes
body CHANGED
@@ -72,6 +72,7 @@
72
72
  ```
73
73
  こうして、実際に画像をアップロードするボタンをクリックすると、
74
74
 
75
+ 先程申したエラーが出ます。
75
76
 
76
77
 
77
78
  現在も原因を探しています。

3

内容修正

2020/06/03 07:41

投稿

ff7575
ff7575

スコア123

title CHANGED
@@ -1,1 +1,1 @@
1
- firebase.storage() というfunctionは無いと言われます。(Nuxt.js)
1
+ firebase.storage() 無い?!そんなバカな(Nuxt.js)
body CHANGED
@@ -1,3 +1,16 @@
1
+ **_plugins_firebase__WEBPACK_IMPORTED_MODULE_12__["firebase"].storage is
2
+ not a function. **
3
+
4
+ **(In'_plugins_firebase__WEBPACK_IMPORTED_MODULE_12__["firebase"].storage()',**
5
+
6
+ **'_plugins_firebase__WEBPACK_IMPORTED_MODULE_12__["firebase"].storage' is undefined)**
7
+
8
+
9
+
10
+ ドキュメント通りのコードを入力したのですが、こうしたエラーがでます。
11
+ [firebase storage web](https://firebase.google.com/docs/storage/web/upload-files?hl=ja)
12
+
13
+
1
14
  Nuxt.jsで、画像アップロード機能を作成しています。
2
15
 
3
16
  定石通り、以下の通りに進めております。
@@ -60,18 +73,7 @@
60
73
  こうして、実際に画像をアップロードするボタンをクリックすると、
61
74
 
62
75
 
63
- **_plugins_firebase__WEBPACK_IMPORTED_MODULE_12__["firebase"].storage is
64
- not a function. **
65
76
 
66
- **(In'_plugins_firebase__WEBPACK_IMPORTED_MODULE_12__["firebase"].storage()',**
67
-
68
- **'_plugins_firebase__WEBPACK_IMPORTED_MODULE_12__["firebase"].storage' is undefined)**
69
-
70
-
71
-
72
- ドキュメント通りのコードを入力したのですが、エラーがでます。
73
- [firebase storage web](https://firebase.google.com/docs/storage/web/upload-files?hl=ja)
74
-
75
77
  現在も原因を探しています。
76
78
 
77
79
  なにか些細なことでも、教えていただければ大変ありがたいです。

2

内容修正

2020/06/03 07:41

投稿

ff7575
ff7575

スコア123

title CHANGED
File without changes
body CHANGED
@@ -44,9 +44,12 @@
44
44
  export default{
45
45
  ......
46
46
  methods:{
47
- const storage = firebase.storage();
47
+ const storage = firebase.storage();//これがダメみたい。ドキュメント通りなのに
48
+ storage
49
+ .ref()
48
- storage.ref().child('image'+this.imageName)
50
+ .child('image'+this.imageName)
51
+ .put(this.image)
49
- .put(this.image).then(function(snapshot){
52
+ .then(function(snapshot){
50
53
  console.log('success')
51
54
  });
52
55
  }
@@ -67,6 +70,7 @@
67
70
 
68
71
 
69
72
  ドキュメント通りのコードを入力したのですが、エラーがでます。
73
+ [firebase storage web](https://firebase.google.com/docs/storage/web/upload-files?hl=ja)
70
74
 
71
75
  現在も原因を探しています。
72
76
 

1

書式の改善

2020/06/03 07:33

投稿

ff7575
ff7575

スコア123

title CHANGED
File without changes
body CHANGED
@@ -56,15 +56,16 @@
56
56
  ```
57
57
  こうして、実際に画像をアップロードするボタンをクリックすると、
58
58
 
59
- _plugins_firebase__WEBPACK_IMPORTED_MODULE_12__["firebase"].storage is
60
- not a function.
61
59
 
62
- (In'_plugins_firebase__WEBPACK_IMPORTED_MODULE_12__["firebase"].storage()',
60
+ **_plugins_firebase__WEBPACK_IMPORTED_MODULE_12__["firebase"].storage is
61
+ not a function. **
63
62
 
64
- '_plugins_firebase__WEBPACK_IMPORTED_MODULE_12__["firebase"].storage' is undefined)
63
+ **(In'_plugins_firebase__WEBPACK_IMPORTED_MODULE_12__["firebase"].storage()',**
65
64
 
65
+ **'_plugins_firebase__WEBPACK_IMPORTED_MODULE_12__["firebase"].storage' is undefined)**
66
66
 
67
67
 
68
+
68
69
  ドキュメント通りのコードを入力したのですが、エラーがでます。
69
70
 
70
71
  現在も原因を探しています。