How can I use scriptaculous.js with GWT Bootstrap in a GWT project - gwt-bootstrap

I have been using animation effects from scriptaculous.js in my GWT project. Recently I have added GWTBootstrap library into my project. After that the effects from scriptaculous.js has stopped working. If I disable the following line
"inherits name="com.github.gwtbootstrap.Bootstrap" in my *gwt.xml then it works again. I dont know whether I can use both scriptaculous.js and Bootstrap in same project. Please can someone who used both help me.
Regards
Nava

GWT-Bootstrap uses embedded copies of bootstrap.css and bootstrap.js by default.
If you need to use your own copies or include other resources, you'll need to create a custom Configurator and a custom Resources.
For more info with samples click HERE.

Related

Shared library from Create React App projects giving (jsx isn't currently enabled error)

I'm attempting to use a shared library for reusable components and using just 2 out of the box Create react apps. One is called 'shared-lib' the other 'project-example'. I made a super simple component in shared-lib, exported (working when I test). I NPM linked both seemingly correctly (shared-lib is in my project-example node_modules with a special icon).
I built the shared-lib, I also imported the shared component (SharedComponent)
import SharedComponent from 'shared-lib'; <- lib is in my node_modules
../shared-lib/src/index.js
SyntaxError: /Users/bemker/dev/portals-modern/shared-lib/src/index.js: Support for the experimental syntax 'jsx' isn't currently enabled (8:3):
Add #babel/plugin-transform-react-jsx (https://git.io/vb4yd) to the 'plugins' section of your Babel config to enable transformation.
I'm following a vid tutorial and he didn't have to eject his create react app, but I'm guessing this is where the error is coming from.
Here is the vid I'm following if anyone wants to take a look. https://www.youtube.com/watch?v=B7iYJT_ll-U
Anyone know why this is occurring, or how to get past it (preferably without ejecting)?
I couldn't find a solution using the above, but there is a package similar to Create React App for building libraries that made it pretty easy. Its not maintained by FB, but it worked for me.
https://github.com/transitive-bullshit/create-react-library
https://github.com/transitive-bullshit/react-modern-library-boilerplate (multiple exports)
vid tutorial using it: https://www.youtube.com/watch?v=N8d-CLmg3hw
second w/ 'real' usage: https://www.youtube.com/watch?v=6R699AQYH74
Hope this helps someone.

Octoperf - Specifying custom / third-party dependencies - where does Octoperf pull dependencies from?

I am exploring the option of using Octoperf as a hosted solution.
One thing that I need is the ability to call some custom libraries (either Java or Javascript / Node.js).
In the SCRIPT PRE and SCRIPT POST examples in the Octoperf documentation I see calls being made to import com.google.common.base.Stopwatch. However, it is not clear to me how Octoperf knows where to pull this dependency from.
Does anyone know if there is a way to specify this and how?
this dependency in your example is already included in every JVM. If you need to add other dependencies in OctoPerf, just place them in the files menu of your project and they will be copied to lib/ext when the test is started:
https://doc.octoperf.com/design/edit-virtual-user/configuration/files/

electron/muon: require not defined in renderer

I'm currently working on an IPFS/Ethereum dapp in Muon.
Because i need Metamask i started with this Boilerplate: https://github.com/SwapyNetwork/electron-metamask-boilerplate
Everything is working fine so far.
However i can not use require('anything') in the renderer process or in html script tags. (See below)
There seems to be a problem with the boilerplate code but i can't find it.
Or is node code in renderer not supported in Muon?
My only change in testing is setting node-integration explicitly to true and
inserting require('fs') in index.js. (i installed fs of course).
I tried many different solutions from stackoverflow and other sites but couldn't find a solution yet.
Error Message
Thank you
As per the muon's github repo:
Some of Muons goals include:
Use the Chromium source directly (eliminating electron's copy of chrome_src) with minor patches
make integrating chrome components less painful
faster and more streamlined end-to-end build process (see browser-laptop-bootstrap).
add support for Chrome extensions
add security focused features for the renderer:
remove node completely (from the renderer process)
full sandbox
scriptable window.opener support
As you can see there, muon does not supports node code in the rendered. It is by design for security purpose. Muon may be great for certain applications, but I recommend switching on to electron if you really need to use require in the renderer.

Using NodeJS module in Titanium Studio

All, I am trying to using third party NodeJS SDK in Titanium Studio. However, I consistently encounter dependency issues, such as util.js, utils.js, ms.js, events.js etc. I tried to add the missing module manually, but it looks like it will become un-tractable as there are so many dependencies.
My questions are :
1. Is that possible to use NodeJS based SDK in Titanium Studio .
2. If so, what is the right approach to include the dependencies.
Thanks a lot!
Titanium can't get Coffee scripts to work natively (assuming you want to deploy the TitaniumWrapper.coffee). A possible solution you may want to try is hooking a plugin http://billdawson.com/titanium_coffee_script/ in order to pre-compile Coffee scripts.
You can also try to embed everything using a Tiwebview that wraps HTML to load mojio-js.js but you would still need to observe events mojio client (like replacing keys, login an user and create a few model instances).
Hope you find the info useful and can serve for further research.

What is the recommended way to customize a component in Lazarus?

I need to customize TStringGrid for my application. What is the recommended way to do it?
The only thing I have seen is to put the TMyStringGrid to a package, install it to IDE and than use it in my application. The problem is that I am working on that component at the same time as on the application and I do not want to reinstall the component every time I do any change in it just to test it.
When I tried to put it to my project it said: "Sharing code between packages and application source is not good idea."
While testing, don't use it designtime, but instantiate it runtime.

Resources