670 Experience
6 Lessons Completed
0 Questions Solved


Posted in User Avatars with ActiveStorage Discussion

Yes, I resolved it. When I trial this, I used Rails 7 alpha2. I need to

  • Install some libvips & make config for it to work --> I think we don't need this if you use Rails 7.0. Because I hear that lipvips are used by default in this latest Rails release
    gem 'image_processing', '~> 1.2'
    # config :vips lib for image processing
    config.active_storage.variant_processor = :vips

  • Remove gravatar_image_tag from Gemfile and use this helper
    def display_avatar_url(size: :middle)
    height = AVATAR_SIZE[size] || size
    if avatar.attached?
    avatar.variant(resize_to_fill: [height, nil])

Posted in User Avatars with ActiveStorage Discussion

I got a problem with line
<%= image_tag gravatar_image_url(, size: 100), height: 100, width: 100, class: "rounded-circle" %>

Error message:
Showing app/views/devise/registrations/edit.html.erb where line #17 raised:
undefined method `escape' for URI:Module

With Ruby3.0, URI.escape was removed

Posted in How to setup Deno with Neovim's COC


I am using Neovim, COC with LSP. I installed Deno for Javascript. It is
Plug 'williamboman/nvim-lsp-installer'
Plug 'prabirshrestha/vim-lsp'
Plug 'neovim/nvim-lspconfig'
Plug 'glepnir/lspsaga.nvim'

The plugins work great, it is fast and helpful. However, I always get the error at "import" statement
Relative import path "@hotwired/stimulus" not prefixed with / or ./ or ../ from

This error happens with this import statement
import { Controller } from '@hotwired/stimulus'

This is very common import statement that I think it was generated by default when creating a stimulus controller.
I am not sure what is wrong and how to avoid it. Maybe, I need to add some config for Deno. But I am not so familiar with this tool.

Could you please let me know how to avoid this issue ?