0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

geochart 日本地図が描画出来ない

Posted at

開発環境

ruby 2.6.5
Ruby on Rails 5.2.5

前提

slim で書いている

本題

上のを参考に日本地図を描画する

ゆくゆくは変数を渡したいけど今回の目標は素の日本地図を描画すること

js ファイルを記事を参考にセットアップ。しかし描画されず

コンソールでは

Uncaught ReferenceError: google is not defined

読み込みエラー


読み込み位置が悪かった

= javascript_include_tag 'application'
script src="https://www.gstatic.com/charts/loader.js"  

ってなってたけど正しくは

script src="https://www.gstatic.com/charts/loader.js"  
= javascript_include_tag 'application'

地図をロードする前にマニフェストファイルを読み込もうとしていた

Image from Gyazo

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?