Giter Site home page Giter Site logo

karad / lein_template_descjop Goto Github PK

View Code? Open in Web Editor NEW
394.0 23.0 16.0 168 KB

A Leiningen template(Clojure/ClojureScript Project) for Web based desktop application with Electron (atom-shell).

Home Page: http://descjop.org

JavaScript 1.49% Clojure 92.53% HTML 5.98%
clojure electron html clojurescript desktop-application om reagent re-frame om-next packager

lein_template_descjop's People

Contributors

dvcrn avatar karad avatar karadtmp avatar mopemope avatar qinxij avatar toku345 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

lein_template_descjop's Issues

Provide configurability for Electron version

It would be useful to be able to specify a specific version of Electron to target, perhaps via configuration settings in project.clj. This would allow developers to control this and get you out of the business of releasing updates whenever a new version of Electron is released.

Update template

Many of the dependencies are now a long way behind and could do with an update. I would send a pull request but am hitting build issues after upgrade.

local db?

Hi m8, I was wondering if it would be possible to add a local sqlite db in the template, and how this could be possible.

Error while going through the setup instructions

Hello @karad ,

I was trying out this template, it's really promising for my use case but I ran into the following error at almost the final step.

descjop1 git/master*  72s
❯ lein descjop-figwheel
Figwheel: Cutting some fruit, just a sec ...
Retrieving figwheel-sidecar/figwheel-sidecar/0.5.9/figwheel-sidecar-0.5.9.pom from clojars
Retrieving hawk/hawk/0.2.11/hawk-0.2.11.pom from clojars
Retrieving strictly-specking-standalone/strictly-specking-standalone/0.1.1/strictly-specking-standalone-0.1.1.pom from clojars
Retrieving figwheel-sidecar/figwheel-sidecar/0.5.9/figwheel-sidecar-0.5.9.jar from clojars
Retrieving hawk/hawk/0.2.11/hawk-0.2.11.jar from clojars
Retrieving strictly-specking-standalone/strictly-specking-standalone/0.1.1/strictly-specking-standalone-0.1.1.jar from clojars
Exception in thread "main" clojure.lang.ExceptionInfo: Call to clojure.core/refer-clojure did not conform to spec:
In: [2 1] val: :as fails at: [:args :exclude :op :quoted-spec :spec] predicate: #{:exclude}
In: [2 1] val: :as fails at: [:args :only :op :quoted-spec :spec] predicate: #{:only}
In: [2 1] val: :as fails at: [:args :rename :op :quoted-spec :spec] predicate: #{:rename}
In: [2] val: (quote :as) fails at: [:args :exclude :op :spec] predicate: #{:exclude}
In: [2] val: (quote :as) fails at: [:args :only :op :spec] predicate: #{:only}
In: [2] val: (quote :as) fails at: [:args :rename :op :spec] predicate: #{:rename}
:clojure.spec.alpha/spec  #object[clojure.spec.alpha$regex_spec_impl$reify__1200 0x55c14260 "clojure.spec.alpha$regex_spec_impl$reify__1200@55c14260"]
:clojure.spec.alpha/value  ((quote :exclude) (quote [reduce transduce into merge map take partition partition-by bounded-count]) (quote :as) (quote core))
:clojure.spec.alpha/args  ((quote :exclude) (quote [reduce transduce into merge map take partition partition-by bounded-count]) (quote :as) (quote core))
 #:clojure.spec.alpha{:problems ({:path [:args :exclude :op :spec], :pred #{:exclude}, :val (quote :as), :via [], :in [2]} {:path [:args :exclude :op :quoted-spec :spec], :pred #{:exclude}, :val :as, :via [], :in [2 1]} {:path [:args :only :op :spec], :pred #{:only}, :val (quote :as), :via [], :in [2]} {:path [:args :only :op :quoted-spec :spec], :pred #{:only}, :val :as, :via [], :in [2 1]} {:path [:args :rename :op :spec], :pred #{:rename}, :val (quote :as), :via [], :in [2]} {:path [:args :rename :op :quoted-spec :spec], :pred #{:rename}, :val :as, :via [], :in [2 1]}), :spec #object[clojure.spec.alpha$regex_spec_impl$reify__1200 0x55c14260 "clojure.spec.alpha$regex_spec_impl$reify__1200@55c14260"], :value ((quote :exclude) (quote [reduce transduce into merge map take partition partition-by bounded-count]) (quote :as) (quote core)), :args ((quote :exclude) (quote [reduce transduce into merge map take partition partition-by bounded-count]) (quote :as) (quote core))}, compiling:(clojure/core/async.clj:9:1)

Could you please help me out?

Doc and details?

Hi there, thanks for sharing this template,
I was able to create a re-frame helloworld / pomodoro app in a couple of hours without knowing much about electron, so thanks!

Could you provide details about the project structure?
As far as I understand there's a piece of node code src/project/core.cljs
and a piece of html + js code app/.../index.html + src_front/....

When the electron framework starts, the node server will run the nodejs code. The nodejs code will create the windows that display & run the html pages.
What about creating new windows? How do you communicate between the client and the server?

`:jsload-callback` should call core/mount-root instead of start-descjop!

Hey, I think there is a subtle bug in the profile dev init files.

The :jsload-callback (effectively) calls core/init!; however, it should instead call core/mount-root. This is an important distinction, because the core/init! function should run things once when the application first loads, and core/mount-root should be called every time figwheel reloads.


Bug is here:
https://github.com/karad/lein_template_descjop/blob/master/resources/leiningen/new/descjop/reagent__src__front__profile__dev__init.cljs#L10

:jsload-callback should instead call mount-root:
https://github.com/karad/lein_template_descjop/blob/master/resources/leiningen/new/descjop/reagent__src__front__core.cljs#L10

Getting started problems

I'm not sure if it's meant to do this, but using a clean install of 0.5.2 project for both om and reagent give the results:

"X" does not work.

in the electron application when started (where X is "Om" for the om project, "Reagent" for the reagent project).

I'm on Mac OS/X.

Also, I'm firing up the figwheel listener as recommended using "lein trampoline figwheel frontend" which starts the autobuilder and says "Prompt will show when figwheel connects to your application", but I don't know how to get it to do that.

Going to "http://localhost:3449/index.html" gives "Cannot find:/index.html", presumably because of the figwheel_middleware.clj handler always returns a 404.

I think what I'm missing and what would be usefully documented are the next steps from a basic install for:

  1. figwheel prompt working
  2. any resources showing
  3. om/reagent working in the electron window
  4. an explanation of the link between figwheel and the electron app, for instance, do i need to run both at the same time for live code changes? If I only need to run figwheel, what URL do I go to in my browser to connect figwheel and see the browser version of the app? or doesn't it work like that?

Sorry for all the questions, but I'm still trying to piece together the parts and their interaction, plus because I'm getting "X does not work", i'm not sure if it's because I'm missing the next step, or the setup is broken, and how to go about fixing it.

cant run when make app distribution version

return "" (.resolve path "") code.

need change

(.loadUrl @*win* (str "file://" (.resolve path "") "/app/index.html"))

to

(.loadUrl @*win* (str "file://" (.resolve path (js* "__dirname") "../index.html")))

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.