Skip to content
This repository was archived by the owner on Sep 10, 2024. It is now read-only.
This repository was archived by the owner on Sep 10, 2024. It is now read-only.

Unable to set viewport_width #14

@benrudolph

Description

@benrudolph

First off, great gem. I love it. I've been running into an issue though when setting the viewport in Shrimp's config. My code looks like this:

 Shrimp.configure do |config|
      config.viewport_width = 1080
      config.margin = '0cm'
      config.rendering_time = 3000
 end

And then I get an error:
undefined method 'viewport_width=' for #<Shrimp::Configuration:0x007fda0fb741e8> (NoMethodError)

I pointed to a cloned version of the shrimp gem and got it to work by moving this line to the last line in the hash literal (ie moving the viewport_width and viewport_height above the file opening in initialization). I do note that I'm not using a config.json file, though I have tried and I still get the same error.

Ruby Environment Manager: rbenv
Ruby Version: 2.0.0-p353
Rails Version: 3.2.13

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions