Giter VIP home page Giter VIP logo

pageflow-timeline-page's People

Contributors

danielkuhn avatar tf avatar upsworld avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

pageflow-timeline-page's Issues

troubles with pageflow-timeline-page and pageflow-react in pageflow 0.11.0

tried versions pageflow-react 0.1.0 and 0.1.1
(When i don't include pageflow-react in the Gemfile i get errors when initialiting pageflow-timeline-page plugin)

Now in preview and published pageflow i get:
Encountered error "ReferenceError: pageflow is not defined" when prerendering pageflow.timelinePage.Page with...

this comes from the line
pageflow.timelinePage = pageflow.timelinePage || {};
in pageflow/timeline_page/components.js
i also tried the pending pull request...

in the editor the page is working fine

any hints? thanks in advance and greetings

ActionView::Template::Error (ReferenceError: window is not defined):

Hi,

I'm currently trying to get the timeline Plugin to work.
Looking at solved issues like #2 or "unsolved" #3 did not solve my issue.

I'm using pageflow (0.11.3) with gem 'pageflow-react', git: 'https://github.com/codevise/pageflow-react.git' (0.2.0.dev) and gem 'pageflow-timeline-page' (0.1.0).

Adding Rails.application.config.assets.precompile += %w(react-server.js components.js) to my assets.rb and using the adviced content for components.js

//= require i18n
//= require i18n/translations

//= require pageflow/react/components
//= require pageflow/timeline_page/components

Didn't solve it either.

Do you have any idea how I can solve that?
Some other issues state, that probably the usage of jQuery inside of some components can cause this.

It's just a new clean installation of pageflow from this Gemfile:

source 'https://rubygems.org'

gem 'pageflow'
gem 'state_machine', git: 'https://github.com/codevise/state_machine.git'

gem 'puma'

# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
gem 'rails', '4.2.6'
# Use mysql as the database for Active Record
gem 'mysql2', '>= 0.3.13', '< 0.5'
# Use SCSS for stylesheets
gem 'sass-rails', '~> 5.0'
# Use Uglifier as compressor for JavaScript assets
gem 'uglifier', '>= 1.3.0'
# Use CoffeeScript for .coffee assets and views
gem 'coffee-rails', '~> 4.1.0'
# See https://github.com/rails/execjs#readme for more supported runtimes
# gem 'therubyracer', platforms: :ruby

# Use jquery as the JavaScript library
gem 'jquery-rails'
# Turbolinks makes following links in your web application faster. Read more: https://github.com/rails/turbolinks
gem 'turbolinks'
# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
gem 'jbuilder', '~> 2.0'
# bundle exec rake doc:rails generates the API under doc/api.
gem 'sdoc', '~> 0.4.0', group: :doc

# Use ActiveModel has_secure_password
# gem 'bcrypt', '~> 3.1.7'

# Use Unicorn as the app server
# gem 'unicorn'

# Use Capistrano for deployment
# gem 'capistrano-rails', group: :development

# Pageflow plugins
gem 'pageflow-react', git: 'https://github.com/codevise/pageflow-react.git'
gem 'pageflow-before-after'
gem 'pageflow-embedded-video'
gem 'pageflow-linkmap-page'
gem 'pageflow-external-links'
gem 'pageflow-panorama'
gem 'pageflow-text-page'
gem 'pageflow-sitemap'
gem 'pageflow-timeline-page'

group :development, :test do
  # Call 'byebug' anywhere in the code to stop execution and get a debugger console
  gem 'byebug'
end

group :development do
  # Access an IRB console on exception pages or by using <%= console %> in views
  gem 'web-console', '~> 2.0'

  # Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring
  gem 'spring'
end

What am I doing wrong?

Regards

Explicitly require pageflow-react

pageflow/react has to be required explicitly in pageflow/timeline_page/engine.rb otherwise Pageflow::React is not defined in pageflow-timeline-page.rb. At the moment, the following entry has to be added to the Gemfile of each host application using the page type to work around this shortcoming:

  gem 'pageflow-react'

mixin error

Including this in app/assets/stylesheets/pageflow/themes/default.css.scss

@import "pageflow/timeline_page/themes/default";

rake assets:precompile give an error:

rake aborted!
Sass::SyntaxError: Undefined mixin 'pageflow-page-type-pictograms'.
/www/pageflow/.rvm/gems/ruby-2.1.8/gems/pageflow-timeline-page-0.1.0/app/assets/stylesheets/pageflow/timeline_page/themes/default.scss:1:in `pageflow-page-type-pictograms'
/www/pageflow/.rvm/gems/ruby-2.1.8/gems/pageflow-timeline-page-0.1.0/app/assets/stylesheets/pageflow/timeline_page/themes/default.scss:1

without the @import - all css is destroyed.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.