I think too much happened off screen between TFA and TLJ, maybe my memory's a little foggy but wasn't the Republic alive and well in TFA? It seems a bit strange that in the opening prologue they're just like 'Yeah, the Republic died suddenly and The First Order are in charge, lol'