# \[SOLVED\] Action not working unless \`@babylonjs/inspector\` is imported

**URL:** <https://forum.babylonjs.com/t/solved-action-not-working-unless-babylonjs-inspector-is-imported/4988>\
**Category:** Questions\
**Created:** [August 8, 2019, 10:06am UTC](https://forum.babylonjs.com/t/solved-action-not-working-unless-babylonjs-inspector-is-imported/4988 "2019-08-08T10:06:11Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![fmichelini](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/fmichelini/32/3102_2.png) [@fmichelini](https://forum.babylonjs.com/u/fmichelini)\
**Post date:** [August 8, 2019, 10:06am UTC](https://forum.babylonjs.com/t/solved-action-not-working-unless-babylonjs-inspector-is-imported/4988/1 "2019-08-08T10:06:11Z")

</div>

Hi there,

I’m working with actions, and everything was working fine until I removed the inspector from my code.

I’ve set up [a demo repository](https://github.com/kekkorider/babylonjs-actions) so that you can see it with your eyes.  
If you uncomment line 14, the action on the mesh runs.

Is this a bug or I am doing things wrong?

---

<div class="post-metadata">

**Author:** ![sebavan](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/sebavan/32/57_2.png) [@sebavan](https://forum.babylonjs.com/u/sebavan)\
**Post date:** [August 8, 2019, 11:36am UTC](https://forum.babylonjs.com/t/solved-action-not-working-unless-babylonjs-inspector-is-imported/4988/2 "2019-08-08T11:36:20Z")

</div>

The thing is as you rely on some hover trigger you need raycasting and picking. Also the action you use relies on animations.

You therefore need to use :  
import ‘@babylonjs/core/Culling/ray’  
import ‘@babylonjs/core/Animations/animatable’

Those are referenced here: [ES6 - Babylon.js Documentation](https://doc.babylonjs.com/features/es6_support#tree-shaking)

You do not need this with the inspector as it is importing them already for its own use so they do en up in your bundle.

---

<div class="post-metadata">

**Author:** ![fmichelini](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/fmichelini/32/3102_2.png) [@fmichelini](https://forum.babylonjs.com/u/fmichelini)\
**Post date:** [August 8, 2019, 12:20pm UTC](https://forum.babylonjs.com/t/solved-action-not-working-unless-babylonjs-inspector-is-imported/4988/3 "2019-08-08T12:20:57Z")

</div>

Thanks for the clarification @sebavan, it wasn’t that obvious for me.  
Now everything’s working fine 🙏

---

<div class="post-metadata">

**Author:** ![sebavan](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/sebavan/32/57_2.png) [@sebavan](https://forum.babylonjs.com/u/sebavan)\
**Post date:** [August 8, 2019, 12:45pm UTC](https://forum.babylonjs.com/t/solved-action-not-working-unless-babylonjs-inspector-is-imported/4988/4 "2019-08-08T12:45:04Z")

</div>

Yep totally understand, side effects are a pain !!!

And here it is even worth cause it is kind of nested dependencies…

Do not hesitate to ask.
