Sencha Touch 2 : Webstorm Run configuration - sencha-touch-2

I am new to Sencha Touch and working on Ubuntu. Till now i followed the instructions from the Sencha Doc and successfully installed Touch 2.2.1 and SenchaCmd. I have created a sample project "MyApp" and its in the directory "/var/www/MyApp".The sdk "touch 2.2.1" is in the same directory "/var/www/touch 2.2.1" I am having problem running the code from Webstorm directly in the browser. Can anyone tell the configuration i need to make.

Open your MyApp folder in Webstorm
create a new JavaScript Debug run configuration like the following:
set URL to 'http://localhost/MyApp/index.html'
in the 'Remote URLs of local files' field, click twice on 'Remote URL' filed of the topmost tree node (your project root), enter the following URL: 'http://localhost/MyApp'
that's all... Now on pressing Debug the start page of your application will be loaded into Chrome

Related

What do we specify in "mainWindowUrl" property in .testcafe-electron-rc for executable electron apps like atom/vscode?

I was looking at https://github.com/DevExpress/testcafe-browser-provider-electron repository.
To automate electron apps using testcafe, I see we need to provide "mainWindowUrl" in .testcafe-electron-rc . Regular electron apps have index.html files in it which I can pass to mainWindowUrl but I'm not sure what should we pass for executable electron apps like atom.exe/vscode.exe.
TestCafe will show a list of URLs opened during the app initialization time if it fails to find the main window URL. You can specify an empty string as a value of mainWindowUrl, wait until TestCafe shows an error and use links from the displayed list.
To test executable electron applications you should configure the 'testcafe-browser-provider-plugin' in another way. See the Testing an Executable Electron Application section for more information.

How to add JVMOptions in a JavaFX bundle created on Intellij Idea

I'm trying to bundle a JavaFX application adding a JVMOption to able virtual keyboard in my software, adding the "VM options" in the "Run/Debug Configurations" form works perfect in a test context, but when I build a DMG bundle and then run the app the keyboard is not shown. When I inspect the package content directly from the Application folder I found that the file "Content/Java/project.cfg" doesn't have JVM options
[Application]
app.name=Project
app.mainjar=Project.jar
app.version=0.6.1
app.preferences.id=Project_id
app.mainclass=co/Main
app.classpath=
app.runtime=$APPDIR/PlugIns/Java.runtime
app.identifier=Project_id
[JVMOptions]
[JVMUserOptions]
[ArgOptions]
If I add the option manually and save the file, the application works well showing the virtual keyboard.
[Application]
app.name=Project
app.mainjar=Project.jar
app.version=0.6.1
app.preferences.id=Project_id
app.mainclass=co/Main
app.classpath=
app.runtime=$APPDIR/PlugIns/Java.runtime
app.identifier=Project_id
[JVMOptions]
-Dcom.sun.javafx.isEmbedded=true
-Dcom.sun.javafx.touch=true
-Dcom.sun.javafx.virtualKeyboard=javafx
[JVMUserOptions]
[ArgOptions]
Does somebody know how to add these options without hacking any file? just adding it to a configuration file inside the project.
My project was created using Java 8, JavaFX, IntelliJ Idea CE (2019), Gradle 4.8
Add the following to your build.xml file:
<fx:platform basedir="${JAVA_HOME}">
<fx:property name="com.sun.javafx.isEmbedded" value="true"/>
<fx:property name="com.sun.javafx.touch" value="true"/>
<fx:property name="com.sun.javafx.virtualKeyboard" value="javafx"/>
</fx:platform>

Why does page not update after refresh when .cshtml changes

I am trying out Blazor and i do not understand why when changing a component after refreshing the browser page it does not update ? Shouldn't the client update itself similar to how angular does?
It only refreshes when i restart the blazor server.
Index.cshtml
#page "/"
<h1>Hello, world!</h1>
If i change lets say the text inside the <h1> to Hello people , i save the project and i refresh the page ( as i am advised in the Blazor tutorial) shouldn't i see Hello people ?
After Asp.net Core 3.0, Runtime compilation is enabled using the Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation package.
To enable runtime compilation, apps must:
Install the Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation NuGet package.
Update the project's Startup.ConfigureServices method to include a call to AddRazorRuntimeCompilation:
services
.AddControllersWithViews()
.AddRazorRuntimeCompilation();
or
services.AddMvc().AddRazorRuntimeCompilation();
I guess you are running the app with the debugger connected? this prevents the recompilation. You need to:
Press Ctrl-F5 to run the app without the debugger. Running with the debugger (F5) isn't supported at this time.
https://github.com/dotnet/aspnetcore/issues/5456
You should add or enable runtime compilation in razor pages,
Install-Package Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation -Version 3.1.6
After installing set the startup file as ,
services.AddMvc().AddRazorRuntimeCompilation();
do the following:
Install the Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation from NuGet.
Update the ConfigureServices method in the Startup class to look like below:
services.AddControllersWithViews().AddRazorRuntimeCompilation();
You good to go.
If you go into Tools > Options > Keyboard and search in the "Show commands containing" search box search for "BrowserLink". Find the option that says "OtherContextMenus.BrowserLink.RefreshLinkedBrowsers" by default this is set to CTRL+Alt+Enter. Click "Remove" and then select the "Press Shortcut Keys" input and press Ctrl+S. Next (just to the left of the input) change Use new shortcut in "Global" to be "Text Editor". Click "Ok" until the window has closed. Now Visual Studio shares CTRL+S with both Saving files and Refreshing linked browsers.
(This will only work if your text editor .cshtml, .css, .js, etc. files in the edit window are the active selections) WARNING: if you don't set it to something other than global then it will override the shortcut for Save and you won't be able to save your files.
Adding "services.AddMvc().AddRazorRuntimeCompilation();" and installing the Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation package 6.0.5 will fix the problem but it will ruin the "css isolation". The first thing you will notice is that the footer will lose its position

React-Native - Could not connect to development server (iOS simulator)

Error:
Could not connect to develpment server.
Ensure the following:
- Node server is running and available on the same network - run 'npm start' from react-native root
- Node server URL is correctly set in AppDelegate
URL: http://127.0.0.1:8081/index.ios.bundle?platform=ios&dev=true
I definitely am running npm start. Why isn't this running?
Now I am seeing this Error:
In file included from /Users/*******/f8app/node_modules/react-native-fbsdk/ios/RCTFBSDK/core/RCTFBSDKAccessToken.m:19:
/Users/*********/f8app/node_modules/react-native-fbsdk/ios/RCTFBSDK/core/RCTFBSDKAccessToken.h:21:9: fatal error:
'FBSDKCoreKit/FBSDKCoreKit.h' file not found
#import <FBSDKCoreKit/FBSDKCoreKit.h>
Does the project build succeed in Xcode?
Did you double-check these steps mentioned by facebook:
Make sure that the Facebook SDK frameworks are installed in
~/Documents/FacebookSDK.
Make sure that FBSDK[Core, Login, Share]Kit.framework show up in the
Link Binary with Libraries section of your build target's Build
Phases.
Make sure that ~/Documents/FacebookSDK is in the Framework Search
Path of your build target's Build Settings.
(https://github.com/facebook/react-native-fbsdk)
I myself had some troubles with the final step, but after retrying in a fresh project all worked fine
Example image from web showing the correct search path
If the project build doesn't succeed, you may want to try this.
You should first update your existing FBSDK (if any)
https://medium.com/#alberto.schiabel/react-native-on-xcode-beta-8-0-how-to-fix-initial-build-error-f0225c649850#.439zl5504

running dart project says dart:html is not available for the standalone vm

I used Git to pull a project
I then start IntelliJ, and say: Open Project.
The project itself looks like it has 4 modules, Lab1, Lab2, Solution2, Solution2
I open the full project. In Lab1, i want to run to see how my web page looks, but when i say: Run main.dart the error kicked back is:
C:\code\dart-sdk\bin\dart.exe --ignore-unrecognized-flags --checked --enable-vm-service:51293 --trace_service_pause_events C:\code\workspace\tw_remoting_training\codelab_01\web\main.dart
Observatory listening on http://127.0.0.1:51293
The built-in library 'dart:html' is not available on the stand-alone VM.
'package:remoting_training/remoting_printer.dart': error: line 20 pos 1: library handler failed
import 'dart:html';
^
Process finished with exit code 254
Im not sure what is going on here though. As a secondary option, i will also try to Right-Click on index.html and click: Open with > Dartium but that shows a blank page. It shouldve done 4 async calls which printed strings to the screen.
Is there something I am missing? Is it not running because of it being a module in a project?
If your Dart script imports dart:html or a library that imports dart:html you can run that script only from the Dartium browser (by adding a script tag to HTML that points the that Dart script, or if you run it through pub build or dart2js in any browser), but it can't be run from the console.
With dart:io it's exactly the opposite, it can't be run in the browser.