blaze-tabs icon indicating copy to clipboard operation
blaze-tabs copied to clipboard

The package does not work in a package

Open kjetilge opened this issue 8 years ago • 4 comments

When I try to use this package in another package it complains that it can't find "basicTabs". If I paste the "basicsTab" template in to the html of my package then I get "Error: No such function: isActiveTab". I've tried to include the package in all possible load orders but still no luck. Any one knows whats going on ?

kjetilge avatar Apr 01 '16 16:04 kjetilge

Fixed it. Hours of nerding - dont know exactly how it came to work. However, now if I return a particular slug name from the "activeTab" helper it doesn't do anything- event if I hardcode the slug name to be returned - strange.

kjetilge avatar Apr 06 '16 10:04 kjetilge

Fixed the activeTab issue - had to read the manual :-) The helper was configured like: {{#basicTabs name="" tabs=tabs }}

but actually ha to add: activeTab=activeTab in the helper: {{#basicTabs name="" tabs=tabs activeTab=activeTab}}

kjetilge avatar Apr 06 '16 11:04 kjetilge

+1

shyal avatar Sep 12 '16 15:09 shyal

fixed by adding

ReactiveTabs.createInterface
  template: 'basicTabs'
  onChange: (slug, template) ->
    # This callback runs every time a tab changes.
    # The `template` instance is unique per {{#basicTabs}} block.
    # console.log '[tabs] Tab has changed! Current tab:', slug
    # console.log '[tabs] Template instance calling onChange:', template
    return

in startup.coffee

shyal avatar Sep 12 '16 15:09 shyal