I am new to flutter development. I want to deploy flutter website to my own hosting server. For that i have done following steps.
1. Go to the root folder of your project and do a build in release mode
flutter build web
The next step is to deploy that folder and host it on server. But when i perform above step the folder is generated inside build folder, but source tree is not showing me build folder while commiting, What could be the issue here, I want to commit that folder to the branch.
I am going to use apache web server for flutter web deployment. will this server work with flutter website?
Update: If anyone has similar question apache worked with flutter website
The build folder is usually in .gitignore that's why you don't see any changes after building it. After running the flutter build web, a web folder is created at build, this is the folder you need to upload at the public_html of your server. If you don't see at all the web folder after building, try a flutter clean && flutter pub get and rebuild it again.
Related
I'm trying to use Google Tag Manager in flutter application. Is there any plugin or package which helps to write GTM code in flutter?
I had the same issue a month ago.
I added the GTM dependencies as I would do with a normal android app.
It doesn't matter if it is a Flutter app, you will have an app/android folder in your project in which you can add graddle dependencies.
This is a screenshot of my app/android folder and the .build.graddle file with the gtm dependency added (and also other google analytics ones).
I recommend to follow this steps for android and this for iOS.
If you want to add Google Tag Manager in flutter web project just navigate to web folder in your project and open index.html file. Then copy any paste the required code snippets from Google Tag Manager web container and paste them accordingly that index.html file. Follow this link to get read the full documentation of adding Google Tag Manger to web project.
I'm adding web support to a Flutter plugin which doesn't follow the federated style. I have followed this link and created a new project for the web plugin.
I need to bundle some JavaScript files with my plugin. I tried placing them on the lib/ folder and referencing them from the generated HTML (using dart:html) as packages/my_plugin/jsfile.js.
This works perfectly fine on debug builds, but it doesn't on release builds.
What I'm doing wrong?
Thank you.
In the futter/examples folder there are lot examples of applications. How to build and run them on Android for instance? I tried to open projects using the IntelliJ IDEA framework, but I did not succeed. I.e. the project is being opened, but it's impossible to build it because of undecidable dependences.
run
flutter update-packages
then in the directory of the example
flutter run
I am using Ionic framework to start on a Cordova hybrid mobile application.
Installing Ionoic via NPM was successful and had no issues.
I am running the below command in a directory as shown below.
C:\wamp\www\my_cordova\> ionic start myapp
This creates a new folder called myapp inside my_cordova folder, which is fine.
But it also creates the plugins folder in C:\wamp\www\ folder. This is the case always how much deeper I create the folder structure. Even if I start a project in C:\wamp\www\my_cordova\level1\, still the plugins folder is created in C:\wamp\www\ folder.
The same happens for platforms folder too when I add them. They are created in C:\wamp\www\ folder.
Is this expected or is it something wrong from my side? I expect all the folders(plugins and platforms) to be created within the same folder directory where I start the ionic project.
It's a problem with the CLI. As the path has "www" in it, these issues happened.
When I tried the CLI commands in another path which does now have www in it, all went fine.
I'm using RubyMine 3.1.1 with Rails 3.0.9.
I have the Spree project cloned from Github, and I want to debug the server while working on the code. To do this, Spree includes a sandbox rake command that creates a subfolder (called sandbox) that contains an instance of the rails app, one that refers to the parent directory containing the source as its spree gem.
If I close the original project and open the sandbox subfolder as a new probect, I get the correct run configurations for development and production and I can successfully debug. However, this doesn't let me edit the spree code in the parent directory.
If I'm in the parent directory, the subfolder is there of course, but there's no rails run configurations and you can't add one as it says there is no rails server launcher in the project (or some facsimile of that message).
Anyone know how to make RubyMine recognize the run configurations for a subfolder?
I ran across this conversation that resolved a very similar issue to what you're reporting.
The gist is that you can go into settings | project structure and then add your subdirectory as a source root. Then you can set up your run configuration with that subdirectory instead of the project root.