Fork me on GitHub
#lein-figwheel
<
2016-02-07
>
hoopes16:02:39

after much further review... :on-jsload runs on JS *re*load simple_smile not on first load. got it.

futuro19:02:33

What is the average time people are seeing between saving a file and having figwheel pick up the change?

futuro19:02:52

I'm getting 10-20 seconds on my current project

kamn22:02:25

@futuro: A few seconds at most. Normally less than a second but my projects are fairly small

kamn22:02:59

That few seconds is usually on Windows on the first "reload"

kamn22:02:26

How big is your project and what platform and version are you using?

futuro22:02:05

@kamn: with regards to size, it takes ~20 seconds to build, and the js output folder is 12MB in size

futuro22:02:27

I'm on linux, and figwheel version 0.5.0-1

kamn22:02:00

I am not an expert at figwheel but that seems weird that you have to wait as long for a figwheel change as a full build

kamn22:02:29

I suspect a weird config in your project.clj

futuro22:02:54

yeah, it definitely doesn't seem right

futuro22:02:01

but I don't know enough about figwheel to know how to assess what's wrong

futuro22:02:59

it might be because it's recompiling my entire project every time

futuro22:02:13

figwheel_server.log says as much

futuro22:02:28

welp, now to figure out how to stop that, or shorten how long that takes

kamn22:02:44

You are using lein?

kamn22:02:05

Do you have optimizations set for cljs?

kamn22:02:35

like :optimizations :advanced

kamn22:02:51

in your project.clj

futuro22:02:02

specifically, I haven't defined :optimizations at all

futuro22:02:15

but adding :optimizations :none doesn't change the compile time

futuro22:02:21

it still takes ~17 seconds

kamn23:02:10

Sorry I can't help you more

kamn23:02:20

I don't know

futuro23:02:45

no worries

futuro23:02:50

thanks for talking it out some with me simple_smile

kamn23:02:21

Yea I can shot some other small ideas your direction but it is sort of like "Meh try this"

kamn23:02:22

Maybe try a newer or older version of figwheel. 0.5 was a major refactor

kamn23:02:37

Copy from some other projects project.clj

futuro23:02:51

I'm currently looking into cljsbuild, maybe the problem is there

futuro23:02:20

It's probably either that figwheel shouldn't be having cljsbuild build the project anew every time, or cljsbuild is doing something wrong

futuro23:02:29

well, those are the first places I'm looking

bhauman23:02:05

@futuro: add :recompile-dependents false to your compile options

futuro23:02:40

@bhauman: wow, massive cljsbuild speedup

bhauman23:02:20

@futuro: that means you had a lot of files depending on the file you were working on

bhauman23:02:48

Or at least something that was really an intense compile like core async

futuro23:02:51

I am using core async, so that's probably a part of it